How many ounces ??

My little girl will be 3 months on the 15th. I give her 3 1/2oz (breast milk) & every time I pick her up to burp her she starts crying, looks anxious and starts licking the burp cloth or her glove. So that obviously means she’s still hungry right ? So I give her another half an once make it 4 oz and she’ll drink it all. She’ll still cry once done, but calms down right away. The problem with giving her 4oz is that she spits up after a couple minutes so I think it’s too much for her tummy. Her pediatrician said 3 1/2 ounces is too much for her that I should even try to give her 3 😳. There’s no way I’m going down to 3. I’m just confused and don’t know if I should stay at 31/2 or 4 and let her spit up. Is there something I can do so she won’t spit up? After burping her I still hold her upwards for another 15 min. I don’t want to underfeed my baby what would you mommy’s do?