There may very well be legal restrictions, some USA jurisdictions prohibit such acts… simple call to the city attorney’s office will give you the details, if any… then again, if you don’t know, don’t ask, and don’t tell
I know this because I lived in a small town where this was prohibited by both village and county ordinance. Ran across a small pet urn in the garden while the village-man was there fixing the run-off ditch (some drunk went off the road, found the bar-ditch all muddy and soft - thankfully, or he would have found my house instead!) ANYWAY, his comment was along the lines that he wondered what the former owners had done with their dog. They were in Florida and wouldn’t pay to have it shipped to them… I had to pay a hazmat fee to dispose of the urn+ashes and that wasn’t cheap either! So please, check first.