The technical answer to your question is: You must alert the public entity on whose land you found it on. Eg.: city, county, state, or federal, etc... Now is that the answer you wanted, or did you want the realistic answer?
Such was the case of a fellow who was exploring caves (DIDN'T EVEN HAVE ANYTHING TO DO WITH METAL DETECTING!) in Death valley area, along the emigrant trails. He supposedly found some items that had been stashed there, like a travel trunk, with some clothes, personal diary, personal effects, etc... Like a steamer-trunk kind of thing, that someone had off-loaded in the mid-1800s, and hidden. Like to lighten their load, thinking perhaps they'd come back for it later. The fellow brought the items from down out of the mountains, and gleefully turned them over to the authorities. I guess he figured this was a nobel thing to do, so these things could be in a museum where they belong. The hiker/explorer was actually a history buff, so it was a double-pleasure for him, I suppose. But imagine his surprise when he was berated, and given the "3rd degree" because he had "disturbed" the "context" of things he'd found. I suppose he'd violated "collecting" clauses, "cultural heritage" clauses, etc... They told him he should not have touched anything, and gone and gotten authorities, etc... Now of COURSE if they gave him all that grief, you can BET he was not going to have been allowed to have kept any of that, right?
Or, imagine this: You are detecting in the public park in your town. You get a deep signal at the base of a 100 yr. old tree. You dig up a mason jar full of gold coins, obviously buried there from the days when the town was in infancy, and perhaps a house had been where the park now is. You gleefully go to city hall, and say
"Hi, I found this in *your* park. Can I keep it for my own fun and enjoyment? Or does it belong to the city, or the city museum, for all to see and enjoy?".
Heck, to be honest with you, even THEY can't say "go ahead and keep it". Because:
There are state-level lost & found laws, that state that items worth over $100 (or whatever threshold your particular state happens to have) must be turned in to the local police dept. for proper lost & found procedures. Notice that the law makes no distinction for when YOU think the item was lost, or buried. Ie.: 1 month ago vs 100 yrs. ago. I mean, let's face it, it is *entirely* possible that someone buried that jar of gold coins yesterday, afterall. Ie.: "how do you know?". So the law doesn't allow people to rationalize by saying "gee, it's been here for years, so no one will ever claim it, etc...". Afterall, insurance companies fight over things (like shipwrecks that get found) that are hundreds of years old. So there is no statute of limitations, and the lost & found laws, therefore, make no distinction. And they also do not say how an item is valued. Ie.: if a gold ring has $90 intrinsic melt value of gold, yet sells for $200 when new in the jewelry store, it's not up to YOU to decide "gee, I think it's under the $100 cut-off. Because otherwise, people would "find" other people's I'pods, etc... and say "but it only had $3.72 worth of instrinsic plastic, silicone, wires, etc... and thus I was under no obligation to go through lost & found laws".