It’s not a fallacy. They charge to maximize revenue. If they charge more, people buy less. If their cost to produce goes up, their optimal price likely goes up, depending on elasticity.
This is Econ 101. Draw some supply-demand curves, compute total profit, increase costs, and see how the optimal point moves on the curve.
Historically companies do raise prices as cost to produce increases.