You can create an animation inside of Unity. You can animate a gameobject and save it as a *.anim file in your assets folder. Creating the anim you open up a timeline, scroll to keyframes in time and then change a component property while the anim is in record mode. Anyway see how to do it in the tutorial video.
This kind of thing can be useful for things like collectable coins, powerups, etc. that you don't want to write code for and are basically going to repeat the same animation in a loop. At least that's what using it for in a racing game I'm working on.
Source Code: https://github.com/omarvision/Animate...