In many ways London isn't just a centre for the UK, it's also a centre for Europe. i.e. if we assume a natural tendency for most young people who are able to want to move to a more metropolitan area, then London is pretty much in the list of destinations for all European countries in a way that virtually no other city is to that extent, and it has to do with language.

For example I'm in the Netherlands in my early twenties. I know pretty much 3-4 people whose German or French is good enough to consider studying or working in say Paris or Berlin. Compared to that I can easily name 100 of my peers whose English is good enough to study or work in the UK. So if they list their destination choices, it's basically Amsterdam & London miles ahead of anything else, and then come some Dutch cities like Utrecht or Rotterdam or Haarlem. Paris and Berlin are sort of on the list, but with the caveat of either 1) having to take a job that's way below what you could have had in the Netherlands or UK, a job where language isn't important, e.g. waiting tables when you have a Master's in marketing, because landing a marketing job on your level in German or Spanish or Italian or French is just not doable without knowing the language very well. 2) investing a few years into mastering the language, a significant (opportunity) cost.

Of course there are exceptions, like international English-speaking companies/jobs in France, but you'll find most jobs in Germany require German, in France requires French, in Spain requires Spanish, same for university education (although English programmes are rapidly on the rise, particularly at the Master's level and in certain fields like business schools), and obviously not everyone in Europe speaks fluent English, but if you look at the ratios, language should play a major factor.

Either way, at the end of the day young people in say Spain either choose Madrid or Barcelona or a few other cities like Sevilla/Valencia, or London. In the Netherlands they choose Amsterdam, a few smaller cities, and London. In France they choose Paris, maybe Marseille or Lyon, and London. etc etc.

In effect, London is the top destination city for the EU, a union of 500 million people who require no visa or permission or anything like that to move and work anywhere else in the EU including London, and 40% of them speak English as a second language. Every other city is either not the top dog (e.g. Liverpool), or excludes hundreds of other millions of Europeans straight away on the basis of language (e.g. any city in the Netherlands (99% of EU doesn't know Dutch as 2nd language), Germany (86% of EU doesn't speak German as 2nd language), Spain (93%), France (86%), Italy (97%) etc). Then add to that a similar language-driven attraction from the US, Asia, middle east, who must all be rich as they'd need a visa, and you get this ridiculous demand for London fuelling network effects and feedback loops. The demand has led to some pretty perverse mass-gentrification as of late and to a large extent it's from natural (language, in particular) causes I think rather than very specific British policies which obviously also play a role but not a dominating one I think (outside of course the concept of the EU which plays a huge role in not discriminating between any member of the EU and prevents the UK from just having to deal with the problem of balancing London as a centre of the UK and forces it to deal with the problem of balancing London as a centre of the EU, but that's an EU policy not a UK or London policy).