Select two cabinets that suit your under-desk storage needs. If possible, get two cabinets of matching height. Matching color is nice, too, but certainly not important to the structure of your desk.
Select an old door to use as your work surface. Most doors will be wider than the depth of your cabinets, but that is OK. If the door has a hole for a handle, position it toward the back of the desk to serve as a cord organizer.
Space the cabinets appropriately and set the door across the tops. Check for levelness and stability. If the fit is uneven, use scrap lumber to shim the shorter cabinet until the door is level and stable.
Mount two posts from your scrap lumber to the back of the door to prevent the overhanging part of the door from overbalancing. Mount one post in each corner and attach using a power drill and wood screws. Drill the screws through the corner of the door and into the end of the posts. Note that many doors have a hollow core. This won't make the connection less solid, but it will feel odd if you are not used to it.
Consider mounting the door to the front of the cabinets by drilling a screw down through the door and into the top of the cabinet. An alternative is to drill holes and bolt the door down, thus preventing a sharp screw tip from hanging down into the cabinet area.
Disassemble the entire desk. Sand any rough edges and paint or stain the components to your taste. Reassemble the desk.