Although the easiest route (no-fault eviction) is being abolished soon, wanting to sell a property remains a valid reason to evict.
Some people just buy property as a speculative investment.
I do not think it is the main cause of shortages in London - that is people buying holiday homes, which are often large and centrally located. London provides a lot (restaurants, nightclubs, gambling, prostitution, financial services...) that attracts people with a lot of money to spend from all over the world.