The people that own the building might want to do something else with it and since they own it that's their choice.
Well, that depends. One could argue that by allowing you to establish a home in their apartment building (in exchange for rent), they've taken on a responsibility towards you. Nobody can build up a decent life if they were under the constant fear to be evicted. That's why as a tenant, you are especially worth of protection from arbitrary actions would make you lose your home, no matter if the building you live in belongs to someone else. In other words, there must be a very good reason for the landlord to make you move out, such as e.g., they need it for themselves to live in.
At least that's one way of seeing it.