Using a GPS alone may not be enough for localization, is it fused with an IMU? What are the other sensors available?
RTAB-Map uses a Graph-based SLAM approach, in which GPS values are added to the graph as constraints. It needs a least a continuous source of local localization estimation like odometry, then when GPS is not available, it just continues to estimate without those constraints.
Another approach is to fuse odometry with GPS using an EKF filter, like
robot_localization package.
In both cases, you need an odometry approach that is able to estimate localization while GPS is not available.