Automatically create webmail.domain.tld redirect

Hey guys,
i'd like to automatically create a webmail.domain.tld forward to https://domain.tld:81/roundcubemail upon the creation of a site on ISPConfig.
Is it possible? Which are the steps to do?
I guess I need to automatically create a DNS record webmail.domain.tld and an apache vhost pointing to the webmail address. Any hint is appreciated.