The Museum of History in Canada has a cool solution to this regarding some of their indigenous artifacts.
They either come to an agreement with the people who the historical item belongs to for the museum to keep it, or they give it back with either a placard explaining why the item is no longer at the museum, or reproduction in its place with a sign explaining that its a repro.
Some of those artifacts have questionable ownership claims. Its not obvious who exactly they belong to. It would be easy enough to return something to a major museum at the country of origin, but for example the Benin bronze statues have claims from nigeria the country and the royalty, who plan to integrate it to their private collection, aka we would be "returning" an important artifact to some kleptocrats safe.
Also nigerian museums are notoriously famous for "loosing" artifacts which then appear on the black market. Sone are even melted down and sold at the price of the materials.