Yes, it is possible to charge an NiMH battery with that circuit. Just not reliably, and no, it would not be safe.
∆V charge termination is fiddly and unreliable at best. Worse, it is not a state, but a single event, and events can be missed. This is an easily missed event, so there is the definite possibility of uncontrolled overcharging, and it is even fairly likely.
And of course, cells will often exhibit false voltage depressions at various points during a charge, especially fresh NiMH cells. So its just as likely your microcontroller will terminate the charge much too soon.
dT/dt is the most reliable, safest, and preferred method for charge termination of both NiCd and NiMH cells when you are charging at a relatively high rate like 1A. This requires a temperature sensor, which you will need anyway if you want to build a safe charger. You cannot make a charger that is safe without it being able to sense the battery's temperature. If a charger can't do that, it cannot be safe. It's as simple as that.
Temperature sensors are a dime a dozen and cheap as anything though. Any thermistor will do as long as you know its resistance tables and have them programmed on your µC. You simply charge at a constant current, with a hard voltage limit as well. I.e., it will charge at 1A unless the voltage needed to maintain 1A rises above some set level. If it does, the charger will simply stay at that maximum voltage and the current will fall. This is because the chemical reactions in the cell are not purely current driven, there are different (and unwanted) reactions that normally don't occur, but can if enough voltage is applied to the cell. Most manufacturers seem to agree that this cutoff is about 1.8V per cell for NiMH batteries. So you want to charge at 1A, but only if you can do so using less than 1.8V.
You do that while constantly doing a running calculation on how fast the battery's temperature is rising. As soon as it starts increasing faster than 1°C per minute, terminate the charge.
Even this alone is not enough however, because a cell with high internal resistance will charge at a lower current (due to the 1.8V maximum) and may not ever actually be dissipating enough power to heat that quickly. It will instead just heat up until it vents (explodes in a controlled manner) from pressure. A safe charger requires a failsafe, which is a temperature charge termination failsafe. Terminate the charge due to temperature rise, but also terminate it if the battery reaches a certain temperature. 50°C is really the maximum you should ever aim for, but 45°C is going to be a little safer and will probably help with cell longevity.
Finally, while this is neither required for effectiveness or safety, it is good to have a timer termination as well. Yes, a third charge termination system. This is literally just a timer, set for the maximum reasonable amount of time you feel like a cell could ever take to charge (remembering that old cells with higher internal resistance could take quite a while longer to charge than brand new cells) and always terminate the charge due to the timer if the other termination conditions fail to ever occur first. This prevents the charger from cooking a weak cell for hours or days, keeping it at 40 degrees C or something but the cell is at equilibrium thermally, and just sits like that. NiMH cells do not like heat, and that will artificially age the battery very quickly, and have a very negative impact on its current condition and long term usable life.
The simple answer is: don't use an op amp as a comparator. Especially, don't use an early op amp such as an LM358 as a comparator with a single 5 volt supply. Use a real comparator - if you like oldies, an LM311 will give you much better results.
Your LM358 is not remotely able to drive a high level anywhere near 5 volts. 2 volts is more like it. I suspect this is what you're seeing in your "incremental" level shift.
If you do use an LM311, make sure to connect a pullup resistor from the output to +5.
Best Answer
I'm afraid you've set yourself up for a Learning Experience. I'm not trying to be disagreeable, but you've done pretty much everything wrong you could.
1) 741s are only specified down to about +/- 5 volts. Trying to use one at 3 volts single-ended is never going to end well.
2) 741s have limited input common-mode range, typically within about 2-3 volts below V+ and above V-. That is, you cannot tie an input to the V- pin and expect the chip to work. Maybe it will, and maybe it won't, but if it doesn't you have nobody to blame but yourself.
3) 741s have limited output swing, typically within about 2-3 volts below V+ and 2-3 volts above V-. So, if the output works at all in your circuit, you'd expect several volts on the output regardless of the inputs. This, in fact, seems to be what's happening - your relay is always on. However, it would not be at all surprising if some 741s operating in this circuit would always have a zero output - and there is no way to tell in advance.
So, the short version is that 741s are intended to be used with both + and - power lines in the range of 5 to 15 volts, centered on ground. Input signals should be within the range of 2-3 volts less than the power supplies, and also centered on ground. You should not expect output voltages outside the allowed input range, and maybe even less if you're trying to provide a lot of current.
It's perfectly possible to use a 741 in single-supply operation, but it takes more knowledge than you have right now, so don't try it until you get more experience.
For your circuit, you should get a real comparator which is specified for 3 to 12 volts power supply voltage.
Finally, even if you do get a proper IC, your circuit will ALWAYS behave as it does now. Since pin 2 is tied to ground, pin 3 will ALWAYS be greater than pin 2, and the relay will always be activated.
With a 10k base resistor to T2, you will not be guaranteed enough output current to turn on the relay. Using a 12-volt relay at 3 volts should never work at all. That fact that it seems to do so says that something very wrong is going on in your circuit.
As has been mentioned, you also need to add hysteresis. As it stands, even if everything works (and you've changed the pin 2 issue), the circuit will chatter uncontrollably when the solar voltage is near the trip point. When the voltage gets high enough the relay will activate and the solar cell will try to supply current to the charger. The combination of relay current and charger current will load the solar voltage, which will drop. The comparator will detect the low voltage, turn off the relay, so the voltage will rise, and the whole cycle will repeat.