I have not done this myself, but it should be no problem. I’ve been looking into this because I have a family member who wants to boot Windows from an external drive.
As you know you absolutely can boot macOS from an external drive. You can also boot Windows from an external drive, but it is more of a pain to set up. So, if you can do both individually there should be no reason why you can’t do both on one drive.
This is the guide I found people using for how to set up Windows on an external drive:
http://bleeptobleep.blogspot.gr/2013/02/mac-install-windows-7-or-8-on-external.html
You’ll have to first partition your external drive of course. You might also want to search for references to this link on the web or on MacRumors. There may be other people discussing exactly what you want to do or sharing experiences. But I think it is pretty straightforward.