Hey there Emily,
These flies could be fruit flies, fungus gnats, or phorid flies. The latter are probably the most difficult to control and can be notoriously annoying in their spread to other colonies and their resilience. I've had phorids in a couple of colonies and it ultimately took a couple of months of regular maintainence just to erradicate them.
Phorid flies will often have a little "hump" on their back and are notorious for their scurring. If your flies run around frequently when disturbed and don't instantaneously take off to flight, they are probably phorids. A
The good news is they are indeed freeloaders - and while they can certainly stress the roaches out in high populations they will not kill or harm the roaches directly. The phorids and fungus gnats simply use the roaches waste material and a breeding resevoir (frass, dead skins, etc) and fruit flies are just mooching off the remains of food.
You'll want to do a few things to control any fly:
1) Keep the bins/substrate in the enclosure drier -> One of the best controls for any flies.
2) Remove dead bodies and skins more frequently
3) Replace food scraps more frequently - both moist food sources and dry food sources
4) Depending on how you have the bin setup; introducing ispods and springtails can be beneficial (I do this for naturalistic setups)
You can employ other strategies as well: I've used a funnel trap for fruit flies before. You can probably find out how to make one online with pictures as my description will pretty gimpy, but if you take a glass cup and place a piece of fruit in it, then add a funnel on top facing into the cup so that it funnels INTO the cup, the flies will fly into it to get the food but are not smart enough to fly back out through the small entry hole at the end of the funnel, therefore getting trapped between the glass and the outer lip of the funnel... if that makes sense. You can place a small one of these in the roach bin or outside of it to control fruit flies.
Ultimately - all of these guys are pretty annoying in cultures. Sometimes the best thing to do if it starts to get obnoxious is to simply tear the whole thing down and start fresh with new egg flats and a complete overhaul. You don't need new roaches, but a fresh (or freshly cleaned) bin and fresh decor, food, etc usually does the job.