You can probably get a pretty accurate measurement by integrating water pressure over time and taking an average, and you could probably reduce error further by using an array of pressure sensors.
It's not a direct measurement. If you put 100 mL of water into a cup, it will raise the water level of the cup by some number of cm. You can calculate this based on the topography of the cup.
Similarly, we can calculate the volume of 600 btons of ice when turned into water, and we know the surface area the oceans, so we can calculate the ocean level rise of inserting 600 btons of ice worth of water into the oceans.
In addition, they do do direct measurements of ocean level. You can learn more about one way these measurements are performed here[1]. That direct measurement tells us the real rise each year. That in combination with the calculated measurement I describe above allows the scientists to conclude that the loss of ice mass in Greenland contributed about 40% of the total sea level rise in 2019.