"map" and "mapDiv" are conventions we use to work with the map object. You are free to use either, as long as you are consistent. "mapDiv" may be a bit better to use because it differentiates itself from the actual map object, which you see in the map constructor.
In the screenshot you attached, "mapDiv" refers to the div element which hold the map object. This can be resized or otherwise modified. The "map" in the screenshot is an actual Map object, with an ID of "mapDiv".
"map" and "mapDiv" are conventions we use to work with the map object. You are free to use either, as long as you are consistent. "mapDiv" may be a bit better to use because it differentiates itself from the actual map object, which you see in the map constructor.
In the screenshot you attached, "mapDiv" refers to the div element which hold the map object. This can be resized or otherwise modified. The "map" in the screenshot is an actual Map object, with an ID of "mapDiv".