Append
and Prepend
have now been added to the .NET Standard framework, so you no longer need to write your own. Simply do this:
image.Layers.Append(image.ParentLayer)
See What are the 43 APIs that are in .Net Standard 2.0 but not in .Net Framework 4.6.1? for a great list of new functionality.