@Lucifer_ gave you the definite answer to "how" but there is no answer to asking "why" since its like asking for the directions for the edge of the planet
I think it could very much be her hormones. Many women get mood swings while pregnant. I would say, you are trying your best to be a good man to her by being there. I would suggest to bring it up to her about how it's making you feel. Hope this helps