I remember being a little confused by the concept when I first met it. As I understand, it is simply a tool to help you solve the problem.
This isn't really something that can be explained easily in a few sentences. But you use virtual work to find forces, and virtual forces to find displacements. You really need a textbook to learn this. Essentially though, if we allow a static system to undergoe a virtual displacement, the work done by all the forces acting on the system must equal zero.