Is it ok to listen to loud music when I have tinnitus, or will it make it worse?

Possibly. The worst thing for tinnitus patients is loud noise exposure. You need to protect your ears from loud sounds or risk further damage.
No. Bad idea, loud music will make worse and may cause permanent hearing loss. Listen at a reasonable level, loud enough that the music masks or covers the perception of tinnitus so you notice it less or don't notice the tinnitus at all, but not so loud that someone has to yell to get your attention. Listening at this level is a great way (one of the best) to deal with chronic tinnitus.