I think they explained it, the reason they could afford it was because Monica’s grandmother lived there, and they’ve been paying 1950s rent because of rent control or something. Something similar for phoebe as well. Anyway show never explains how joey/chandler/Ross can afford those big houses.
I think Singapore handles it well, any residential property can only be rented for minimum of six months, less than six months and it must be registered a commercial property and be in a zone that allows commercial activity.
It doesn’t ban AirBnB specifically, but it solves this problem.