You have a basic fan that doesn't have a timer function to continue running after the light is switched off, you may want to change that for one that does have this function (just over £20 in TLC I think).
Otherwise connect Eart to earth, Blue to Blue, then select whichever one is NOT the permanent live out of the Red & Yellow (probably Yellow) as this is the switched live, and use this, it will be off when the light switch is off & live when on.
The fan will stop as soon as you turn the light off though, and after a while you will wish you went for the timed version

Good luck.