If you wired the rear light directly to the dynamo, you wouldn't be able to switch it on or off. It would just be on all of the time.
And might damage the rear light, if it gets high voltages direct from the dynamo. Though modern lights should have some sort of overvoltage protection built in.