You need an old HP utility, originally released as SP27608.exe, that is no longer available from HP. You can find it on a number of sites by searching Google for that download, but I don't know which of them are free of malware.
Here's a source for it as
HPUSBBOOTTOOL.zip I know is clean. The zipped file contains:
* HP USB disk storage format tool V2.0.6 HPUSBFW.exe (renamed hpflash1.exe). This installs the Drive Key, the program that creates a bootable flash drive.
* A second compressed file that contains Command.com from DOS 7 (Win 98 SE) and boot files, such as a CD ROM driver, etc. required to do more than you'll need until you want to do more DOS tasks that may require them (see below).
1. Extract the files, and Install DriveKey, the utility that actually creates the bootable flash drive.
2. Place the added files in a folder under the installed program folder, C:\Program Files\DriveKey.
When you run DriveKey, it will prompt you for the location of your boot files. You then delete any DOS files you don't need and add any other DOS programs and files you want on your bootable drive. You can create "specialty" drives by making a folder that includes just the boot files and the DOS program files you want to use in a single folder and pointing to that folder to create the drive.
I've used these drives to run DOS versions of Ghost, Partition Magic and NTFSDOS, a utility that allows you to boot to DOS and read files on an NTFS formatted drive.
I have successfully formatted flash drives with DOS 7 and DOS 6.22. I have not been able to make it work with any version of DR-DOS. You can get boot files for other versions of DOS from bootdisk.com.