bf hits my cervix when doing cowgirl HELP

okay so i had sex with my bf for the first time today, and it was great! at one point we wanted to try another position besides missionary, so i was like BET lemme ride this mans (you know, like cowgirl). so i got on top all fine and stuff but immediately it hurt not because it hurt going in but i think he was hitting my cervix which was very uncomfortable. we also had this problem when we tried doggy, and it was painful there too.

i really want to be able to do both of these positions because they do feel good up until he hits my cervix and i know he loves it too. i know it could just be an issue of me getting used to him because it was our first time, but still, any tips for this would be great thanks!!