How can i export mail accounts?

I just bought a new vps and i want to know how can i export my email accounts to the new vps

I already installed hestiacp on the new.

if source server is hestia, use hestia backup engine. If not, have a look at imapsync, will do the job.