How to replace drush_download_file in Drush 9
With Drush 9 dropping support for the drush dl command, the need for keeping a download function was dropped. 

The remnants of drush_download_file() were dropped into the SyncViaHttpCommands.php example class to demonstrate creating a custom a Drush commandfile. You could copy that as a template if you're looking to mimic the old drush_download_file(), or you could use the Guzzle client or some other PHP function; use what works best for your command's download needs.