A ballast resistor can be mounted ANYWHERE will fit and and it will work fine. The extra length of wiring won't hurt a thing. Just don't stick it where resistor heat will be a problem - like on the gas tank(!)
I like to hide the resistor on a bracket fastened to a rocker box bolt so the resistor is positioned above the rocker box. It's hidden away nicely, and it has plenty of cooling airflow.