How can I achieve this situation?
:!ls
Try :help NERDTreeChDirMode. Setting it to 2 will do what you want.
:help NERDTreeChDirMode
2