Have you spoken to your headteacher? They have a duty to look after your health and wellbeing so should be willing to listen. Maybe there are some small changes to your workload they can make that will help. Have you got any classes that could easily be taken over by someone else (e.g. year 7s) or could they let you go home if you are free in the afternoons? Try not to feel guilty (easier said than done!). If the welfare of your baby means you need time away then so be it. They will manage without you. I needed a couple of weeks off for being unwell when pregnant. The effect of the time off on my wellbeing was huge and definitely worth it.