Unless it was destroyed (or left behind, like the priceless Kurlan naiskos) in Generations...
Clearly it was just a replica Picard keeps in his ready room.
Hard to imagine Starfleet just leaves all their stuff on the planet for anyone to pick over. I posit there's a big time-cut between Picard/Riker beaming up and the Faragut leaving orbit.
Maybe sometime after "Ship in a Bottle", the containment unit containing Moriarty was transferred somewhere else. A Starfleet research facility, for example. The cube may not have been on the ship when it crashed.
In ST Beyond, we learn starships have these big vaults for collecting priceless stuff, and the plot is set in motion when Spock files the Abornath and the entry is relayed to the villain. Certainly the vaults are to be emptied at some point - but Krall apparently rests assured that Kirk would not leave the Abornath at the Yorktown station.
So, when do they get cleansed of these relics? At the conclusion of each five-year mission, thus finally establishing how a "five-year mission" is defined? But Picard never was on such a mission, so perhaps nobody ever emptied his vaults...
OTOH, given replicators, there would be little problem in having a unique object aboard a starship. With the push of a button, the unique object could also be found at fifteen museums, two private collections and one lab shelf marked "odo ital".
As regards Moriarty, he probably was Picard's dirty little secret never entered into a log or otherwise revealed to the broader Starfleet. Picard just hoped the problem would go away, but didn't have the heart to press "delete" at any point.
Since the ship was more or less intact at Veridian III, quite possibly Moriarty survived till the moment when the torpedo volley from the Farragut finally vaporized the saucer.
Timo Saloniemi