As someone asked in a comment why would this lead fewer new houses being built; the logic of the developers is rather simple, e.g.:
Deutsche Wohnen CFO Philip Grosse said in an interview with Bloomberg that the firm is holding off on construction in Berlin, and instead will look to other cities to make new investments. The company said earlier this month that limits on raising rents and potential mandated rent cuts put cash flow at risk. The damage done to its bottom line, the landlord calculated, could be to the tune of 330 million euros ($363 million) over five years.
Basically, why invest in Berlin if their local government has given indication they are [now more] likely to "screw you" (as property developer) in the future? The problem, like always in such matters (of capital flight), is one of signalling.
Yes, the local government could pick up the shovel/tab and build more social housing compensating for the likely lower private investment. The question is: will they (raise enough taxes etc. to do it)? Also, a local government has basically zero powers to impose capital controls.
Regarding Simon's comment that Deutsche Wohnen is not actually a house builder: that is fair criticism of their statement, but not so much of my argument. Keep in mind that they've acquired over 100K apartments in Berlin presumably by offering higher prices than the competition to the former owners (most of which appear to have been large-scale realtors as well.) Ultimately a developer has to sell his product, unless he plans to rent it out himself.
To give you a parallel here: many [tech] startups don't make it big by going the IPO route but manage to recoup the investment by selling to a larger (and usually fairly monopolistic) firm/competitor. If the latter route did not exist at all, it would leave only one route to startup investors to make a profit. For housing, the exit of big buyers from a market basically leaves the developers with fewer routes to recovering their investment: sell to some small owner (who might need credit to buy in the first place) or become a rental company to some extent.
As an interesting, perhaps, aside here: Deutsche Wohnen appears to be largely owned by Deutsche Bank, so in some sense people are "renting the house form the bank", one way or another. (There is some difference as to whom carries the risk of default and who gets the long-term benefits [but also risks] of holding an asset in the [US-style] "ownership society" vs [German] "rental society".) But if we use this blurring analogy, Deutsche Wohnen exiting the [Berlin] market is roughly similar to a large bank exiting the mortgage market in a city, i.e. there's an implicit statement here that "it's not worth it", i.e. a form of lowering the "credit score" of the city as far housing development goes.
As one article notes
Less obvious advantages of [large] scale [residential portfolio companies] are comfortable loan conditions. According to Standard & Poor’s, Vonovia has a long-term corporate credit rating of BBB+, with a stable outlook. Unimaginable for a homeowner or private real estate investors, this allows for loans not secured by mortgages.
It's also interesting perhaps that an even bigger fish, Vonovia tried to buy out Deutsche Wohnen, but this [2016] bid was rebuffed. The history of bank mega-mergers seems to have parallel in Germany with the merger [attempts] of mega-residential-property companies.