In general we recommend avoiding using the ‘head tag’ for any complex customizations. Instead, you should look at getting set up with a proper git-based theme.
Once you have that, then yes DModal is the probably what you need. We have some documentation on that here: