Yes, O2 sensors only see Oxygen
"Rich" for an O2 sensor is low oxygen in the exhaust, as an example ALL properly working exhaust systems with Cat Converters run RICH, as far as rear O2 sensor is concerned
O2 sensors make their own voltage via a chemical reaction with Oxygen(which is why O2s wear out, they run out of chemicals)
O2 voltage
0.10 volt is High Oxygen, "lean"
0.90 volt is Low Oxygen, "rich"
The upstream O2 sensor gets exhaust straight from engine
The computer cycles injector open times to try and keep O2 voltage at around 0.4 volt, optimum oxygen level that means good burns in cylinders
Downstream O2 sensor(after Cats) should run at 0.7 to 0.8 volt, so "rich"
Cats use up most of the Oxygen left in exhaust to burn up pollutants in the exhaust, so there should be Low Oxygen levels in the exhaust After the Cats, so "rich" exhaust, but not really, lol
Now when a cylinder misfires the unburned oxygen makes the O2 sensors voltage drop(0.1v) on that bank/side of the engine
So computer responds by opening the injectors longer, this causes all the cylinders on that bank to have a rich mix, say there are 3 cylinders(V6)
Well the 2 working cylinders will output less oxygen because of the NOW rich mix, too much fuel, which compensates a little for the misfiring cylinder that's outputting too much oxygen
And computer will set Lean code because it is opening injectors longer than it calculated to compensate for the higher oxygen level on that bank
So Lean Code means too much oxygen on that bank, not too little fuel
When a cylinder/engine, is actually running lean on fuel it will ping/knock, and it will smoke if its running too rich on fuel
So lean code is about oxygen in exhaust at the upstream O2 sensor(s), not downstream
That can be caused be an exhaust manifold leak as well or loose O2 sensor, it sucks in oxygen
Or partially blocked exhaust, it holds in the oxygen at the upstream O2s
And of course misfires and partial misfires, not as much oxygen is used
And then of course the usual suspect, intake air leaks, computer calculation is off because of unreported air coming in