Implement the Root.copy method
Move the code for creating copies of installation roots to the `Root` class.
Simplify the implementation, so it should be easier to change it later.
(cherry picked from commit c6842bbe3885abbb4e83db0e9e3af401e41c1fcb)
Related: rhbz#2093793