There's many things that are good things. However, you need to balance them against the cost (money, space, time, whatever) required to achieve them. For some smaller roads, the cost might not be worth the benefit.
The cost of things should indeed be considered. Depending on region, tax money subsidizes every mile driven (one well done source here https://www.theatlantic.com/business/archive/2015/10/driving... but there are many, many others). A switch to cycling amounts to a much lower subsidy per mile, so if we want to talk costs then the argument for cycling infrastructure becomes even stronger.
Encouraging people to exercise and not drive gas-powered vehicles is a net win for not only their long term health but also the environment. It's worth it.