Samsung's Galaxy S8 and Galaxy S8 Plus flagships are now supported by DualBootPatcher, though this only applies to the international version running on Samsung's own Exynos 8895 processor. The patcher works by modifying the phone's ramdisk to be receptive to custom ROMs with multiboot flags, then patching any ROM the user wishes to flash where it's told to, rather than overwriting the ROM already in the phone's internal memory. The mod requires TWRP recovery to work, and while it may work on phones whose bootloaders have not been unlocked, it won't do much good, since the device will refuse to boot up the patched ROM.
The first step to get the app working is to ensure your device has an unlocked bootloader and TWRP recovery. Getting all of those pieces into place will require a Windows or Linux PC, Android Debug Bridge software, Samsung's ODIN flashing suite, and a bit of time and work. If all of that is ready, however, you can simply download and run the DualBootPatcher app on your computer to patch up your device's ramdisk, then patch one or more custom ROM ZIPs of your choice, flashing them wherever you want. From there, you'll have to use the app on the PC to flash the ROMs, and patch up the bootloader on your device to allow the use of bootui. Anybody who dual-boots a computer will find it familiar; it's similar to the GRUB bootloader used to choose between operating systems when booting a PC. After that's all set, simply choose which one to boot when the device starts up.
There are more than a few caveats to this approach. For starters, using this to save space on your phone's data partition won't help. While putting a ROM on the MicroSD card or user space of the internal storage may save system space, the data and apps for the ROM still end up on the data partition. Another warning is that this will only work on the Exynos variant of the Galaxy S8 and Galaxy S8 Plus, and trying it on the Qualcomm Snapdragon 835 versions is a serious risk. Also, when using the PC app to patch your phone's ramdisk, you have to ensure that you have the proper device selected; the program uses a special partition table to enable patches, and can make some partitions too small for system files if you're not careful, rendering your device partially or fully inoperable.