I even run the command prompt as Administrator but it didn't work for me with the below error.
'keytool' is not recognized as an internal or external command,
operable program or batch file.
If the path to the keytool is not in your System paths then you will need to use the full path to use the keytool, which is
C:\Program Files\Java\jre<version>\bin
So, the command should be like
"C:\Program Files\Java\jre<version>\bin\keytool.exe" -importcert -alias certificateFileAlias -file CertificateFileName.cer -keystore cacerts
that worked for me.