If you are getting divorced in Spain the courts will try to apply the relevant law of where the marriage was took place
So if you were married in UK and plan to divorce in Spain then the Spanish court will apply English law (or Scottish) where possible
If you are divorcing in the UK then all assets of the marriage will be determined and settled by the courts or in a divorce settlement agreement between both parties and their solicitors
So in short I would suggest that as the house in Spain it is a joint asset (and possible joint liability if you have a mortgage or debt on the property) via marriage and usage etc. Same as a car, a stereo, garden shed etc
If you are considering a divorce then suggest you go and see a divorce solicitor ASAP. If it is a general query for wahtever reason again go see a solicitor for certainty