How to cd to different drive windows?

I am trying to change directories in the windows command prompt. With the cd command, I can go anywhere inside C:\ drive, but I cannot go to any other drives.

cd D:\

I am trying this command, but it is not working. Can anyone tell me what I am missing here?

To change a directory, you need to add a /d after your cd command.

cd /d D:\

Try this It works for me.