Building more houses is not always the best solution to a housing shortage.