Using Secure Settings, we can set an immersive mode that will be handled by Android properly. It doesn't use accessibility (which slows down the phone). It uses a policy in secure settings to directly tell android that it should assume the user has hidden keys (I.E. an application has requested fullscreen).
To use this application, you must grant the application the WRITE_SECURE_SETTINGS permission. You'll need ADB. You can find tutorials online on how to install it for your OS.
Now, type this into a shell:
adb shell pm grant com.draco.immersive android.permission.WRITE_SECURE_SETTINGS
The app can handle 2 types of immersion (they do not work at the same time). There is status bar immersion, which will hide the status bar, and there is navigation immersion, which will hide the navigation bar. There is a reset button to disable immersion entirely.
This app may not be compatible for all phones, but it SHOULD work for Android OS 4.4+
Enjoy! Here is my donation link: https://www.paypal.me/LockscreenMods