Assuming you've created the variable path for maven as follows:
Under System path, click new
then edit as follows:
Variable name: MAVEN_HOME
Variable value: C:\Program Files\apache-maven-3.5.3\bin
Then continue with these instructions:
Under System Path, update variable path by clicking on edit and add:
C:\Program Files\apache-maven-3.5.3\bin;
immediately after:
C:\Program Files\Java\jdk\1.8.0_161\bin;
remember to add semi-colon ;
after \bin
as included above and then run your cmd prompt and type:
mvn -v