Ownership. You will not own your apartment, it will be owned by your landlord and you will pay him whatever he demands. You will not own the forest, either. The state will, or some private entity will. No trespassing.
You can still own and buy appartements in most places in the world. Then there are many forms of social housing.
Rent to own is also a possibility but not seen in most countries.
Seems your problem is not ownership but landlords.
Some countries in Europe have the right to roam on any land. State owned and private owned. (Maybe more countries somewhere else have it to but I donāt know)
It does not need to be so terrible. In some places it just is because of profits
Owning an apartment and owning land are wildly different. The housing structure alone is not the entirety of home ownership.
Since weāre just talking hypotheticals anyway, letās say in the second image the land is actually owned by the owners of the apartments, like a co-op.
There is no such thing as universal right to roam in the US. Likewise, apartment ownership (we call them ācondosā when you can own one rather than rent) exists here, but by far is the minority option in multi-family housing. You can claim you want to buy a condo or apartment as much as you want, but that doesnāt do you any good when no one is selling. Units are built to be rented which is a recurring revenue stream, which big capital likes a lot more.
The significant problem is not that nobody is whacking out slabs of apartment housing fast enough. The issue is that our underlying capitalist system is fucked, and a simple anti-car attitude is not going to fix that.