I might be wrong, but key store have size restriction on some devices (2ko basically), so it might be the cause or wrong algorithm, see https://developer.android.com/privacy-and-security/keystore
You might adapt your app to use a different way or refuse some device with api levels too low