How to replace drush_download_file in Drush 9 drush_download_file() existed in includes/drush.inc for Drush 8 and below, but this has been removed in Drush 9 as far as I can tell.

Is there a standard way that file downloads should be executed in custom commands written for 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.