Wheel travel is how far each of your tires can move up and down. It is usually dictated by the length of your shocks, bump-stops, anti-sway bars, and the overall design of your suspension,
Suspension Flex refers to how well all the suspension components work together on all four corners to keep the tires on the ground over rough terrain. You could, for example, have a vehicle with great theoretical wheel travel but find you have almost no suspension flex because your springs are too stiff. This is often the case with full size trucks, as the suspension is set up for carrying heavy loads as a priority over flex. It is also possible to have too soft and flexible a suspension. A rig that flops and rocks over every bump is unsettling to drive, can be a roll-over hazard, and can push driveshafts past their normal operating angles. As with most things, you are after a balance.
As you can see in the photos, my Jeep TJ had fairly equal wheel travel on all four corners. Upward travel (Compression) was limited by bump-stops just before the tires snagged the fenders, and downward travel (Droop) was limited by the suspension arms and the shocks. The Jeep was very well balanced and controlled when the suspension flexed thanks to slightly stiffer than stock shocks and heavy-duty front springs that could support the weight of the big winch and bumper.
When you talk about suspension flex one of the first topics that will come up is Anti-Sway Bars (often just called Sway Bars). Their purpose is to keep the body of the vehicle parallel to the axle, on the theory that the axle is parallel to the road, and the road is level, so everything is level. Of course once we get on unmaintained roads this is often not the case. The ideal is for the body to remain level regardless of what the axle and tires do. Some vehicles have sway bars front and rear, some only have them in front. Some vehicles can have sway bar disconnects put on for trail use, others can't. A quick google seach of Sway Bar Disconnect and your vehicle should provide a wealth of info for your rig.
The purpose of Bump-Stops is to limit suspension travel before damage occurs to other components. If, for example, your shocks get over compressed the shafts can bend, the mounts can break, and the seals can blow. Bump-stop extensions are often included in lift kits, either to protect the longer shocks that came with the kit, or to allow for larger tires by reducing upward wheel travel. These extensions can be longer replacement stops, or spacers that go under them. Avoid replacement stops that are far harder than stock, as they will make for a jarring ride on rough roads.
Stock shocks are chosen by the manufacturers based on budget and average use, not on what makes the vehicle the most capable. They may be slightly shorter or longer than is ideal, they may have short shafts in a long body (low efficiency), or they may be too stiff or too soft. I'm not saying that you should run out and replace your shocks right away, but as part of a schedule of upgrades, or if yours are worn anyway, look at high-efficiency shocks intended for off-road use.