pip.download: refactor and try to clarify

add _check_download_dir and _download_http_url to ease the understanding
of unpack_http_url and unpack_file_url functions