Lots of people building extensions has limited impact beyond a housing bubble, building hospitals has much wider economic benefit from all the high quality jobs, the better health of the population letting them work etc
Ok, so it allows the state to try and redirect effort and materials towards things the government believes are more worthwhile.
To make a bike example, the government funding bikes for transport would tempt bike shops to refocus their efforts away from serving leisure cyclists.
Or to think of a real example, during the pandemic the government funded tons of laptops and tablets to disadvantaged children, while there was already a shortage of the things. They believed that was more worthwhile use of them than business and personal customers who also wanted them.