"App not installed"

I am trying to put an Android app on website. I am running 11.0.2 on MacOS. I’m downloading 11.0.3 now so I can test there.

I am able to build and install on my device locally using USB and the SAB Install APK feature.

However, when I try to put the app on the internet and download it to the same phone, it opens a wizard to install the app “Staging app” “Do you want to install…” and then it says “App not installed.”

I’ve tried deleting any older versions of the app, restarting my phone, and increasing the Version Code of the app.

I have set the minimum version to Android 9 which is what my device is running.

I also tried disabling Play Protect from the Google Play store, which I saw suggested online. I think that by default that you can’t just install an APK from anywhere but I thought that if the user toggles one option that they should be able to do so. I am not a regular Android user and this is an older device.

Here is what happens when I try to install using adb:

avc:  denied  { read } for  scontext=u:r:system_server:s0 tcontext=u:object_r:sdcardfs:s0 tclass=file permissive=0
System server has no access to read file context u:object_r:sdcardfs:s0 (from path /storage/sdcard0/Download/123Calc-1.0 (1).apk, context u:r:system_server:s0)
Error: Unable to open file: /storage/sdcard0/Download/123Calc-1.0 (1).apk
Consider using a file under /data/local/tmp/
Error: Can't open file: /storage/sdcard0/Download/123Calc-1.0 (1).apk

Exception occurred while executing:
java.lang.IllegalArgumentException: Error: Can't open file: /storage/sdcard0/Download/123Calc-1.0 (1).apk
	at com.android.server.pm.PackageManagerShellCommand.setParamsSize(PackageManagerShellCommand.java:328)
	at com.android.server.pm.PackageManagerShellCommand.runInstall(PackageManagerShellCommand.java:906)
	at com.android.server.pm.PackageManagerShellCommand.onCommand(PackageManagerShellCommand.java:158)
	at android.os.ShellCommand.exec(ShellCommand.java:103)
	at com.android.server.pm.PackageManagerService.onShellCommand(PackageManagerService.java:21740)
	at android.os.Binder.shellCommand(Binder.java:634)
	at android.os.Binder.onTransact(Binder.java:532)
	at android.content.pm.IPackageManager$Stub.onTransact(IPackageManager.java:2796)
	at com.android.server.pm.PackageManagerService.onTransact(PackageManagerService.java:4046)
	at android.os.Binder.execTransact(Binder.java:731)
255|bali:/storage $

So that looks almost like some kind of permissions problem. Not sure if this is just my device or I have some other issue.
Any tips?