I used to be able to get below a planet's surface quite reliably, simply by heading down to the planet in a 45° dive.
The SC drop-out animation took so long - while my altitude continued to fall - that I'd almost always end up inside the planet.
Needed a tough ship for that cos getting back out again did a lot of damage.
More recently, there have been occasions (usually the period between an initial update and it's patch a week or so later) where I see gigantic "ripples" on a planet's surface which aren't actually tangible and, if I fly or drive through them, provide access to the planet's interior.
In an SRV, you'll just "fall" for a few seconds and then reset to a position just above the real surface, fall a bit more and then land on it.
In a ship you can fly around inside the planet until the game realises somehing's wrong and, again, resets you to a position above the surface.
S'funny, back in the 2.x era, if you used the SRV and then panned the external camera around, it was often apparent that there were a variety of game assets (outposts, skimmer sites, rocks, mining rigs etc) present inside the planet.
Haven't noticed that for ages.
I guess it's something FDev have tidied up in some way.
As for the OP's specific issue, I'd bet it's related to the long-standing issue with orbital assets racing away from you when you drop out of SC and seeming to "drift" while you're still in SC.
Basically, I suspect ED has some kind of a mathematical error when dealing with the positions of objects in SC compared to their position outside of SC.
For example, I was messing around at Mitterand Hollow a few days ago and I noticed that almost all of the surface POIs were inaccurately positioned by a couple of hundred metres.
The POIs for crashed ships were a couple of hundred metres away from where the crashed ships physically appear and the POIs for the Geo' sites were near the edge of the site rather than being in the centre of the sites.
Again, my guess would be that, in the case of a fast-moving object, the game is positioning the POI and then, a few milliseconds later, positioning the physical assets and if the planet has moved significantly during that time, we get weird things happening.
Dunno if it's a problem with the game or, perhaps, a problem with slower computers not being able to do the sums and render the sites quickly enough.
In short, the game probably thought it was rendering the OP's outpost on the surface of the planet but the planet moved before it could render the outpost and, thus, it ends up "under ground".