what is important of executing yii migrate in installing advance template

Hi, I just want to ask what is the important of executing command in the console yii migrate if we install advance template ?please enligthen my mind I am confuse

Thank you in advance.

running the migration automatically connects to your database and creates the correct data structure for you in your database. The application will not work correctly without that.

before I will execute yii migrate,do I need to configure first my database in common folder to specify my db ? and then I can now execute the command yii migrate ?

Thank you in advance.