I pulled the same trailer behind our 2011 and had one dealer holler void warranty and I asked him to show me the paper work or section that said void and that ended that talk.
Trailer towing, or even just the existence of a trailer hitch on the bike, CAN be used by H-D to justify refusing warranty claims on a case-by-case basis. If you have a failure that could be shown to have been caused by the added stress of towing, they could refuse that particular claim. However, they can't just void the entire warranty. Towing isn't likely to affect the infotainment system for instance, or a clutch master cylinder failing, or the seat seams coming apart, or many of the other things common to Harley's.
On the other hand, if you have an ESP, that can be totally voided by the ESP company as they state in the contract, and specifically mention trailer towing. As a service contract, they aren't held to the same legal requirements as the factory warranty under federal law.
Jerry