Yii2 api attributeLabels not working


I am new to Yii2, and my basic API is working fine and now i am trying to change the field names which is return from the data base, so i have added attributeLabels() in my model and changed the name for the fields but its not reflecting.

can any one help me on this… below is my model code. (this is for API)

public function attributeLabels()


    return [

        'ID' => 'ID',

        'LOGIN' => 'Login',

        'FIRST_NAME' => 'First  Name',

        'LAST_NAME' => 'Last  Name',

        'EMAIL_ADDRESS' => 'Email  Address',



Did i have to add anything in my controller i have only actionIndex to return all the records. Below is the code from my controller

public function actionIndex()


	$model = Phdlist::find()



	Yii::$app->response->format = Response::FORMAT_JSON;

    return $model;