Bathroom exaust fan replacement
If the only issue is mounting the fan, you can add a 2x4 or 2x6 (whichever matches your joists) perpendicular to your joists and attached to them in the attic. Like building part of a plenum box. Then attach the fan to that. Basic carpentry. I like GRK fasteners but any good screws (or even nails) will do. If you want it stronger you can use brackets but that's probably excessive for something as light as a fan.

Another alternative is to get one of the Panasonic fans that comes with a mounting bracket that spans the gap between joists on the attic side and lets you position the fan as needed. Cost is higher but hassle is less, and they are good fans. I know from experience.