oh yeah, that sounds painful as well!
My experience in the UK and Germany (as a EU citizen and pre-brexit UK) has been that you get there and that's it, you can rent a house you can register with the doctor. There's no special card, there's no police involved. It's how I'd expect the idea of free movement within the EU to work.
I understand the problem with people coming to Spain to just get a surgery but surely for a EU citizen it could be simpler since the idea is that we all have the same rights. I don't think the health system in Spain is much different to the NHS where there's no payment involved.