A 2018 mini shipped with Mojave, so should continue to boot from a Mojave system on an external drive.
If you have the latest system (Sonoma) on your internal drive, and boot from Mojave on an external drive, you will certainly get that notification that it (Mojave) is not compatilble with the system on the internal drive, which it certainly is not compatible.
And, if you try that external Mojave boot drive on any silicone Mac - you should be able to use that drive for file access, but you can't possibly boot from that Mojave sytem on any M-type Mac.