All’s I can figure is that the Soviets didn’t have any active conflict to use as an excuse to test their aircraft at the time. (I searched and couldn’t find this article posted, so I went ahead and submitted it.)
The engines on those Foxbats were very cranky. If you sent a Foxbat to a distant airbase there’s no guarantee that you’d see it back anytime soon.
Also, the Foxbat-B was the recon version. I don’t know that the ‘B’ was anywhere close to available — even in prototype — by the ‘67 War.
The only explanation that I can think of is that the Russians sent a pre-production ‘A’ (interceptor) model to Egypt to buck-up the Egyptians. Recall that the Egyptian Airforce got plastered on the ground in the first hour of the War. It might have been a useful propoganda ploy to send a Mach 3 fighter streaking over the most heavily defended airspace in Israel just to impress the natives.