Boyfriend and I broke up

So tonight my boyfriend and I broke up. We realized that the relationship was starting to get too toxic and we both have started to feel unhappy together. We went through a miscarriage last month and ever since then nothing has been the same between us and I decided to end it. I’m really sad and hurt. I don’t want to break up but I don’t know how to fix this. I don’t know what to do so that we can be happy again together. Some days I’m madly in love with him and he makes me feel so happy and other days, I don’t want to be with him. Idk what’s wrong with me. 💔