Hello, welcome to the website. My name is Tony, I can assist you with this.
If the airline is willing to offer a refund, then yes, you can do this. However, there is no statutory requirement in law for an airline to offer a refund in the event of a flight being cancelled by the travelling party due to illness.
Is there anything you would like to ask me about this?