When someone decides to sell a good because market conditions have changed, the price of the good goes down
Yes i agree with that part
Rental prices are proportional to overall housing prices. In general, more homeowners is correlated with lower rents. Renters are also removed from the market.
That is correlation without causation. When there isn't enough housing, rent and property prices will both be high. However, if properties get taken off the rental market and are put up for sale instead, with no changes to population or overall housing supply, that is going to drive up rental prices. There will be fewer people renting, by necessity, but the people who want or need to rent will not change by as much, creating an imbalance between supply and demand that will drive up rental prices.
Not to mention another thing we haven't touched on which is why landlords are leaving in the first place. Those who remain in the now-less-profitable environment may try to raise rent to compensate.