How to customize download filename?
For this issue there's a prerequisite,that is, your download method must be 'private', otherwise there's no chance for drupal to call your 'hook_file_download', it's important!

Here's an example from drupal's file module, change $file->filename to what you want, then return to HTTP headers.

/**
 * Implements hook_file_download().
 *
 * This function takes an extra parameter $field_type so that it may
 * be re-used by other File-like modules, such as Image.
 */  


  function file_file_download($uri, $field_type = 'file') {
     global $user;
     // Get the file record based on the URI. If not in the database just return.
     $files = file_load_multiple(array(), array('uri' => $uri));
     if (count($files)) {
         foreach ($files as $item) {
         // Since some database servers sometimes use a case-insensitive comparison
         // by default, double check that the filename is an exact match.
         if ($item->uri === $uri) {
             $file = $item;
             break;
         }
      }
   }
   if (!isset($file)) {
     return;
   }  
  
  //...........................other codes.........................  
  
  // Access specifically denied.
   if ($denied) {
     return -1;
   }  
  
  // Access is granted.
   $headers = file_get_content_headers($file);
   return $headers;
  }