Thank you for your message. I just have 2 questions for you before I can answer fully:
Are you still registered in Spain?
Do you still own the property in Spain? If so, are most of your belongings there and are you renting out the property whilst abroad?
Thank you for your response.
When a person decides on their registered home of legal residency, it is where they primarily live and have established a permanent address based on significant family, occupational, economic, political and social ties.
From the information you have given me, Spain strikes me as your home of residency because it has been your home for some time (family and social ties), the majority of your belongings are there and you will be returning to your home in Spain which is not rented out therefore deemed as your home address. You have investments in the UK thus you continue to pay any necessary taxes.
I hope that helps.
*Please rate my answer so I can be credited for it.