I don't like the way you have phrased that. "Animals have the ability to mutate their genetic code" suggests it is under their control somehow; and that they choose when, and maybe how, mutations should occur.
I would rather start from the facts that
1. there are variations in populations (which can be brought about by things like mutation)
2. some of these variations are heritable
3. some of these variations may improve or reduce the chance of individuals surviving and reproducing
From that, evolution is a necessary end result. (It would take divine intervention to prevent it happening!)