For example, if your main domain is example1.com and you have a subdomain named example2.com and Google is indexing it as "example2.example1.com" you can avoid Google from indexing as such.
In the root of /public_html for your main domain example1.com add the following to robots.txt for any add-on domains:
User-agent: *Any additional domains you would add an additional line:
Disallow: /example2.com
Disallow: /example3.com