You will have to but an unlocked phone from the Apple store. If it's only bands then a European iPhone should work on bands 4 and 17. Here I am taking your word for what you need. The phone sold for South America is not the same model that is sold for Europe, however. I'm not sure what the differences are. Here are the model comparisons: http://www.apple.com/iphone/LTE/
It would be a good idea to call your carrier and ask if the modulation standard is the same as for European phones; there's more to LTE than just bands.
Note that if you buy a phone in Spain it will have to be returned to an EU country if it ever needs service. The warranty and service availability is not international.