http to https could be a reason
then you add
www.xyz.a to xyz.a
then you add xyz.a to xyz.b
could be more than accepted by some browsers.
domain set a redirection at your dns provider could ba another. i should rather be configured as cname or A.
for virtualhost, yes it could. but sme server is not built this way. so indeed
it creates two virtualhosts.
i am not sure it would change something for the redirections.
last time i had something similar i rather used a rewrite rule to handle this before displaying the website.
in term of reference for search engine it would be better