@Rflush is correct.
The Mavic system measures
all altitudes relative to the takeoff point. The takeoff point is defined as 0 ATO, and everything else is relative.
The default setting for maximum altitude in the controller/aircraft may be something like 120 meters ATO; this means it won't accept a command to rise higher than 120 meters (400 ft) above the takeoff point. You can change this limit however you like, up to a maximum of 500 meters ATO.
Some jurisdictions' laws may specify a ceiling of 400 ft AGL (above ground level) as the US currently does. This may include a reduced ceiling across canyons or a raised ceiling around buildings and mountains. The Mavic has no idea where the ground is, unless it happens to be hovering within about 2 meters of some object. It does not understand geographical dropoffs or hills at all. Your compliance with the 400 ft AGL rule is entirely on your own mental calculations.
The Mavic actually has an internal barometric altitude device, and the GPS/GLONASS receivers, both of which measures altitude relative to the average sea level. Thus your hometown may be at 2000 ft AMSL (above mean sea level) and the Mavic would use that measurement at the time of takeoff. However, NOWHERE on the controller screen nor the DJI Go app screen will you see altitude described this way. This is only used for internal calculation.
By the way, many people have flown Mavic above 14000 ft AMSL (by taking off from locations high in the mountains). Aerodynamically, propeller thrust gets weaker as the air gets thinner, so beware of underpowered flight if you try to go much higher than this. At least one report of a flight over 18000 ft AMSL.
If you stand on the top of a skyscraper, or in the bottom of a canyon, all of these measuring systems may clash. Your country or the country you visit may have different rules that include buildings, airports, population density or other hazards to avoid. It's up to you as a pilot to be aware of these and fly safely.