To your existing lines of code, include this additional line:-
;C:\Program Files\nodejs\
This will enable you to end your Path variable on the "User variable" section of the Environment Variables on the System Properties. Once concluded, reopen your command prompt and type
npm
Which should help the program work.