It's pretty obvious that the cause of unaffordable housing is elsewhere. But being the one to actually collect rent is a kind of guilt-by-association.
I assume by "incentives", you mean that they'd manipulate the law to limit other suppliers. I'm sure that happens, but as a landlord you don't have to do that. And being a landlord (who isn't manipulating the law) doesn't make the problem any worse.
Criticism should be directed at the real problems. Those are a mix of law and culture and just inertia.
There's an error in your analogy.
Nobody is growing carrots, they're buying carrots
Incentives push the carrotlords to pass local ordinances. 'Show me the incentive and I'll show you the outcome'
and the don't have to do anything illegal to restrict the housing supply - they can lobby, regulate, and vote