It's not actually true that you can "lose the copyrights to your music" if you use pirated software to produce it, is it? That doesn't sound at all true.
No, someone is probably confusing this with something that would be related to derivative works.
Unless perhaps the software ships with audio samples that are granted royalty-free usage to anyone who has a legit license to the software package? Extremely unlikely, just trying to imagine why someone would think this.
That's got nothing to do with trademark one way or the other. The question is whether you can maintain a proprietary interest in something created with tools appropriated form others.