Yes, some babies will 'wean' from it, when on solids.
I would not give him, solids 3 times a day yet.
He is only 5 months old.
Typically, 3 meals of solids a day, is gradually worked up to, during the course of their 1st year.
Give him Formula, BEFORE any solids.
Otherwise he will continue to 'wean' from his Formula bottle.
Yes, for the 1st year of life, breastmilk/Formula is a baby's primary source of nutrition. Not solids and not other liquids. Solids, is not as nutritionally dense, as Formula or breastmilk.
Try asking your Pediatriican, about what you can do.
Or, is he teething?
Some babies will seem to reject the nipple or bottle, when teething, because it is uncomfortable.