No, SetUnitAnimationByIndex plays the animation of a unit based on the frame sequence. So if "Stand" animation is from frame 1 to 1000 and "Walk" is from frame 1001 to 2500. Then SetUnitAnimationByIndex(unit, 0) will play "Stand" animation while SetUnitAnimationByIndex(unit, 1) plays the "Wallk" Animation. Just view the animation sequence in Mdlvis or test each index until your desired animation is played.
Note that each model file can have different frame sequence.
Therefore, index 0 may play "Stand" to some units, while it may play "Attack" or "Spell" or "Walk" to other units. It all depends on the model it is using.