If you think that you are spending too much time or money on gambling, whether online or in gambling premises, then you can ask to be self-excluded.
Yes, it is legal to use a VPN to play at PokerStars if online poker is allowed in your country. However, keep in mind that VPN usage doesn't make an illegal activity into a legal one. So, if you live in a region where gambling is extremely frowned upon, you might still get into trouble.