As a non-resident you should be paying non-resident tax. Your Spanish solicitor will be able to advise.