You could have experienced a post partum depression during that time. May be you didn’t know how to handle that at that time.
Because of those incidents, you both would have lost interest in each other, which made you to distance yourself.
The loneliness is also because, you do not feel wanted.
Next Steps
Do consult a Psychologist in your city. Or, if you feel , you can consult online with me.