Yes, a convex lens of focal length 20 cm can produce a magnified virtual as well as real image.
For a magnified virtual image, the object should be placed between the focus and the optical centre of the lens.
For a real image, the object can be placed anywhere apart from being placed between the optical centre and the focus of the lens.