A boiler expansion tank is part of a sealed system where boiler water contains little oxygen after a short time (unless there is a leak in the system, then the tank rusts out soon as the water touches the shell. The gases to take up the expansion are in the bladder.) Boiler water temperatures are higher than well water, so the diaphragm is made to take higher temperatures if the tank is installed right at the boiler piping (they can also be installed remotely so they are not subject to heat.)
A well expansion tank might have a plastic fitting attachment and a plastic diaphragm less tolerant of hot water. The gas would be in the space between the bladder and the shell with the water in the bladder so it can not rust the metal shell.
An expansion tank for a water heater also has to be able to handle higher temperatures, yet be resistant to damage from the oxygen in fresh water, so it is a combination of the above.