Spain and Greece are reliant on tourists full stop. Not just UK ones. They could reasonably decide to ensure the safety of German etc tourists by eliminating those from higher risk areas such as the UK and Sweden.
The first, even local, outbreak in any Costa will kill the rest of the season
There seems to be a sense of British exceptionalism among some posts. The world no longer revolves around us.