I know in the UK, treasure belongs to the crown, but they will usually pay you a percentage for finding "their treasure". In the US, as long as it isn't something that would be sacred to native tribes, it's pretty much yours. In Italy, I'm pretty sure the government just gets it and there's a bunch of burden put on the land owner while they look for more artifacts (there are stories of people destroying roman documents rather than report them to the authorities).
It seems like Polish law would be the only relevant one here (I don't think EU law covers any of this), and based on a cursory search they seem to be much closer to Italy than the US on this spectrum.
As someone from the US, it was actually quite surprising finding out other countries handled things this way.
'Treasure' being a defined term though, not just literally any non-earth thing you dig up. Finds (that are not known not to be treasure) are supposed to be reported to local coroner to decide/determine its status & next steps.
Here's a summary of what counts: https://finds.org.uk/treasure/advice/summary