Go to Settings > Security (or Privacy) and enable "Install from Unknown Sources" (on Android 8+ this is handled on a per-browser basis).
This is a critical question. Using an older APK introduces potential security risks because version 1.6.5 was released before many modern Android security patches. However, since Gravity Screen Off Pro only uses sensor data and device admin rights (no internet access in the background for analytics in this build), the risk is relatively low. Gravity Screen Off Pro 1.6.5 APK -Android-