I think that it would be more realistic for Iran to produce a 4th generation platform, perhaps a delta wing configuration ? 70-100 4th generation fighters would be great for the airforce in Iran.
As for 5th gen, I don't see Iran purchasing or producing any such platform for at least another decade. That's not a bad thing though since by then 5th gen fighters will be more mature and much cheaper to purchase and maintain.
The Russians are badly in need of funding for their future weapons platforms like the SU-57 / Armata tank etc. Perhaps Iran can provide some funding in exchange for a few dozen SU-57's and Armata tanks ?
Right now neither China nor Russia seem interested in selling Iran a 5th generation fighter. The Chinese are keen on selling Iran the JF-17, but Iran seems to be more interested in the J-10, which is China's more expensive and capable export variant.
Of course if Iran is looking at a SU-30 like platforms then the Chinese J-11 would be the Chinese equivalent. The Chinese variants are $30-$40 million while one SU-30 is $60 million.
I've heard rumors that Iran was genuinely interested in purchasing approx 30 x J-10s from China. However the main issue of contention between the two seems to be the payment method.
You see Iran wants to pay China in oil and barter, whereas China wants Iran to purchase the jets using hard cash / foreign currency / gold etc Of course because of the current economic situation Iran is not too interested in giving up its foreign currency reserves.
One thing to keep in mind is that unmanned platforms seem to be playing an increasingly prominent role in present wars. When it comes to investing in unmanned platforms, Iran definitely made the right choice and is heading in the right direction in that regard.
When it comes to replacing its aging fleet of fighter jets, Iran seems to be weighing all of the available options very carefully.
Basically a 5th gen F-16.
75 of these and 75 of SU-30 could keep Iran airforce afloat for next 20 years until Iranian domestic projects take off.
All in cost will be less than 20B of maintenance and spare parts. (not sure the exact figure too lazy to do the calculations)
once Iran starts doing its own maintenance and spare parts production plus using Iranian arms (instead of Russian ones) costs will drop for servicing the aircraft.