MODE-2251: Add refresh session method and improve message handling

This PR:
- implements refresh session method;
- handles specific exceptions and generates appropriate error message.