I want to be able to block the allocation/use of particular drive letters when external (USB) devices are attached.

For example, I never want my computer to have an E or F drive.

I can remember back in the dim distant past of a program TweakUI Powertoy for Windows XP/7 (1996) and one of the features was being able to select from a list of check boxes which drive letters were/were not available. Unticked boxes never saw a device allocated that drive letter.

This is different from simply hiding drive letters

Win 10 2004 19041.572