macOS (Big Sur) Internet installation fails near the end
Below are the steps to install Big Sur from a flash drive when the Startup Security Utility disallows booting from external media.

Use your Mac or another Mac to create the USB flash drive Big Sur installer. See the Apple website How to create a bootable installer for macOS.

Boot to Big Sur Internet Recovery. In other words, start or restart the Mac mini and immediately hold down the Option+Command+R key combination until the spinning globe appears.

When Recovery Assistant window appears, select one of the following options.

Choose an account and enter a password.

Choose Recovery Assistant→Erase Mac… from the menu bar.



Proceed until you reach the image shown below.


If necessary, use the Disk Utility to erase the internal drive. When finished quit the Disk Utility.

Select Utilities→Terminal from the menu bar. This will open a Terminal application window.

If you have not already done so, plug in the USB flash drive Big Sur installer.

Enter the command below to launch the Install macOS Big Sur application from the USB flash drive.
&quot;/Volumes/Install macOS Big Sur/Install macOS Big Sur.app/Contents/MacOS/InstallAssistant_springboard&quot;


Install macOS Big Sur to an internal drive volume.



References
HT208198: Startup Security Utility
HT201372: Create a Bootable Installer
HT211983: Use of InstallAssistant_springboard