because is good, lol nah look at its taylor serious expansion. i.e When you differentiate it once your left with one constant(term without the t) everytime and when you sub in t=0 you remove all the terms with the t. Thus when you differentiate once then sub in zero you'll get E(x) and differentiate twice and sub in zero you'll get E(x^2).

But as you can see for things other than the mean you'll get noncentralised moments.

Centralised moments means just like ur variance is when n=2. However its hard to get all the moments by doing that but we can use the MGF to get all the non centralised moments and it has alot of other uses.