Lying on the back in a frog like position (Knees and hips bent) is normal in early infancy.
How ever you have to look into his mile stones too especially gross motor ones, as he is 5 months now.
Does he have a head control now? Does he turn over?
If these mile stones are not yet achieved, you have to see your Pediatrician
Usually the reflux which babies have normally and end up spitting often, reduces by 4 to 5 months as they gain weight. If reflux and regurgitation persist, you may have to consult your Pediatrician for medications.
Hope you find my answer helpful.