Active Recorder

I need to select data from database where a certain field is null, I write my code like this :

$mainMessages = Message::find()
->where(‘replied_to = :rto && department_id = :did’)
->addParams([’:rto’ => NULL, ‘:did’ => $department_id])
->all();

but it returns an empty array, how can I write the code correctly.

->where(‘replied_to IS NULL AND department_id = :did’)