Because the F-22 is good at shooting down planes and nothing else. The last time I checked, the F-22 is great at sponging up a ton of sensor information, but can’t feed that back to the rest of the aircraft flying along with it (the info is somewhat old). Not that big a problem if all you want to do is blow up things, but very limited in terms of helping other units like ground pounders, not to mention that the -22 can only carry 500lb JDAMs at best. The F-35 can stealthily carry larger air-to-ground payloads and has an improved sensor and data link suite that can support other units once it goes winchester (out of ammo) and can better engage ground-based threats like the much-vaunted S-400 series of missiles. The combined -35 and -22 team can comprehensively cripple even the most advanced A2/AD IADS while feeding high-resolution sensor info for follow-on forces. If you take away nothing else, it is that the -35 brings a much-needed stealthy air-to-ground component into the fight. Also, the -35 really isn’t as bad as the press implies. Even this blog notes that armchair wargamers using consumer-level computer simulations showed that the F-35 can beat its so-called equals like the SU-35BM in relatively equitable conditions.