What is that fan on the toilet cistern for?
I think it’s there to keep the toilet from swallowing too much air when you flush it. The glug-glug noises you hear at the end of a flush are air being sucked down into the pipes after the water, and that air has to get back out of the pipes somewhere or it could back up the whole system. Most plumbing arrangements have a vent pipe for this, and so might this one, but this fan would at least minimize the air being sucked into the pipes by matching or overmatching the suction of the water.
There are fan systems for toilets which vent smells from the toilet pan via the overflow pipe connecting the cistern to the pan. This fan seems like it would do something similar but in case for that to make sense, it would have to vent the air outside the room somehow or perhaps filter them somehow. Or perhaps it’s a extremely poorly thought-out extraction system to prevent condensation on the cistern.