You can't mine Mysterious Shards in Pokemon Pearl because they, and Ramanas Park, didn't exist in Diamond, Pearl, and Platinum.
Now, the first thing you need to understand is that Brilliant Diamond and Shining Pearl are remakes of Diamond and Pearl that came out in late 2021, over 13 years later than when the original Diamond and Pearl released, so you can't expect remakes on a completely different console to have the exact same features as the original, even if BDSP is extremely faithful to the originals. In Diamond, Pearl, and Platinum, the building at the end of Route 221 is called Pal Park, which to sum it up, allows you to permanently transfer your Pokemon from your Generation 3 games (Ruby, Sapphire, Emerald, FireRed, and LeafGreen) to your Gen 4 games. You can read more about this on Bulbapedia.
Because Brilliant Diamond and Shining Pearl were released on the Nintendo Switch, which has Pokemon Home, a very easy way to store and transfer your Pokemon between games, there was no purpose in keeping Pal Park. Instead, they replaced it with Ramanas Park, a place where you can find, battle, and catch legendaries from Gens 1-3 (this is ignoring the shadow Origin-Giratina because that's a bit different). Pal Park and Ramanas Park, albeit similar looking and located in the same place, are ultimately two different things that serve different purposes for their games. So if you were hoping to catch a Latios in base Pearl, you're out of luck.
If by some horrid twist of fate, I am reading this wrong and you are playing BDSP, the Mysterious Shards can be found in the Grand Underground (which is a bit different from the Underground in DPPt) after obtaining the National Dex, although they are rare spawns so you will have to mine a bit. However, I'm assuming that you are playing Pearl, so ignore this bit if you are.
So yeah, basically, you kinda wasted your time, sorry. I hope this did help and you at least found something decent during all your digging. Have a nice day!