When the device is set to have accurate elevation then Intervals.icu will keep the total elevation gain info from the fit file and not recalculate it from the altitude data.
If it still isn’t giving you what you want, then add a Custom Field and select the data from the Fit file.