That is not the whole picture. Most Ph.D programs require you to successfully complete 2 years in a research master program which is based on classes and homework assignments. It's not easy.
After that you enter into the Ph.D. for 3 years(max 4) and you are right, you can almost do whatever you want. Just bear in mind that either you publish in top journals or your academic career ends here.
This is true, but in practice admission in most Ph.D. programs in Spain is not very selective as there are more slots than applicants, so any master's degree will do, even if it's not research-oriented. And for foreign students, many Ph.D. programs have a rule that "if you can prove that your degree gives access to Ph.D. programs in your own country, then you can enter" so it's even possible to be admitted with e.g. a US bachelor's degree (YMMV per university though).
You don’t need a masters in the UK. Three years bachelors and then straight into a PhD which is just research - no classes or teaching. And we produce more than our share of top science so it must work.
You'll have to have a first in order to be able to skip the masters, and since entry to funded programs is competitive, you have to be an exceptional candidate for this to actually happen – it's quite rare.
Then there's the program itself. DTCs (doctoral training centres) now mostly run 3 + 1 programmes, where your first year is a master's, involving taught classes and a research project. This is to get everyone up to speed on how to actually do independent research, and to build core skills.
While it's true that teaching doesn't always form a mandatory part of a doctoral degree, working as a teaching assistant for at least one semester is often mandatory.
In short, you've mischaracterised doctoral education in England and Wales (Scotland may be different) to quite an extraordinary degree. I see no reason to comment upon the "more than our top share" claim, for reasons which are, I hope, obvious.
After that you enter into the Ph.D. for 3 years(max 4) and you are right, you can almost do whatever you want. Just bear in mind that either you publish in top journals or your academic career ends here.