Yii2 is an amazing PHP framework, there are a lot of resources available to help get through issues and learn the techniques. But often times you find certain un-charted issues, one such was the creation of CRUD in the advanced template of Yii2.
If you are trying to create CRUD for the backend in Yii2 advanced template, yo uneed to use the URL
http://localhost/your-application-name/backend/web/index.php?r=gii
And while you will not have any issues generating the model, the CRUD generation requires you to specify the Model Class, Model Search Class and the Controller Class with reference to the backend path, i.e.
backend\models\Model backend\models\ModelSearchClass backend\controllers\Model