Flats can be an excellent way of housing people, but the UK needs to iron out some issues - leasehold reform and reform of management fees, for example, and making sure flats have things like balconies, lifts, proper soundproofing and rules which allow laundry to be hung out on balconies. It can be done. Most European countries seem to manage just fine with many or even most families in apartments.
We need to shift towards properly built flats as senior housing, to persuade more older folk to downsize, as this will free up a lot of large houses for younger people to use. Older people understandably want stair-free living, yet there simply is not enough space to build huge numbers of bungalows (which are very space-hungry and require huge amounts of land per person). Nice, senior friendly flats can also be built in mid-town locations rather than strung out on the edge of cities where there is no public transport and few services. We need older folk to live in more central locations (not next to a nightclub, obviously, I just mean within walking distances of shops, services and a bus route/train station or two), so that people can stay independent if/when they lose the ability to drive safely. Most middle-aged women are working full-time; we can't rely on adult daughters and sons to drive their elderly parents around to appointments and shopping in the way that my (stay-at-home) mother did for her elderly parents when they couldn't drive any more.
Housing a bigger population will also require a move towards public transport and away from cars. Cars require huge, huge, huge amounts of space, not just for driving them but even more for parking them (you have to allow space for them to be housed overnight AND parking spaces in all the places that the car is likely to be).
A lot of the UK's problems stem from the fact that it has the usual English-speaking-country's love of cars (and dislike of public transit, bikes or walking even short distances), but unlike the US, Canada, Australia etc is too densely populated for widespread car ownership to work properly without causing problems. Building your society around cars is OK if you have a small population spread thinly across wide areas - loads of land to house and drive cars AND still have space to build. The UK doesn't have this luxury, so car dependence means clogged roads, parking wars with neighbors, and tiny newbuilds in numbers that are nowhere near adequate.