Stomach problem? Breastmilk allergy?

My baby boy is 2.5 weeks old, whenever he is pooping he looks like he is in pain and he cries. He is exclusively fed breastmilk. I'm wondering if he could have an allergy to my milk? It just seems like when he poops he is very uncomfortable and I hear his belly making noises and he is all around pretty farty... and he seems to poop a little more than 3 times a day, some days. I asked his pediatrician about it and she just said make sure I sit him upright for atleast 20 mins after feedings which I do. Any input appreciated!!