In some cases keytool generates by default keystore in pkcs format instead jks
Verify this with
keytool -list -keystore [keystore_name]
if listed type is pkcs you can convert pkcs to jks with (where .p12 file is your curren keystore and .jks new one)
keytool -importkeystore -srckeystore [MY_FILE.p12] -srcstoretype pkcs12
-srcalias [ALIAS_SRC] -destkeystore [MY_KEYSTORE.jks]
-deststoretype jks -deststorepass [PASSWORD_JKS] -destkeypass [PASSWORD_KEY] -destalias [ALIAS_DEST]