If you've spent so much time with your spouse around, and now you're at home alone, and you're working remote, then you are going to need a lot of socialising outside of work, because remote work does not meet the same needs for seeing people in person (I've been there).
Humans are social animals, we need some interactions with others, and you are just getting way too little.
The issue is not 'how to be alone?', it's how to satisfy your social cravings with in-person interaction, once you have that at least some of the time, being alone for the rest of the time is much easier.