If you increase mortgages to 50 years and keep the number of houses too low, houses prices will go up until the monthly payments return to the level of borderline unaffordability.
Another way to think about it. Longer mortgages means more available buyers (for a given price level). More buyers means prices up.