Before you start an animation, think ahead of what the animation should look like.
Then open your assembly. When you have your assembly open you must do contrains to match the future movement of the assembly. When you are done with contrains open Inventor studio and then click on Animation Timeline. Then you will see the animation timeline in the bottom bar. In tree of part you have to choose part which will be moving. Click on this part by right click of mause and choose make animate contrains.
Now you can see window, where you can create move of your part. You can setting time of animation and etc.