Need help with a simple solar battery charger
4 x NimH cells i series will work very well here. 2 cells are too low in voltage.
Full charge of a NimH cell needs about 1.45V so 4 x 1.45 = 5.8V.
IF the PV panel is 6V at full power (ie > 6V in full sun unloaded) then it is a good match to 4 x NimH cells.  

A switch should be inserted between motor and battery so that the cells can still charge when the motor is not operating. 

If you wanted to optionally operate the motor from solar alone you can add a second switch in the vertical wire from battery +ve to disconnect the battery and allow PV to motor direct powering. 

If possible use a 1N518x Schottky diode.
Any of eg 1N5187 5188 5189  

If not available  a 1N400X is OK and VERY available and cheap
(x = any of 1 2 3 4 5 6 7)

The 1N581X will drop about 0.4 V at full current (1A) but drop to 0.2 - 0.3V as battery approaches full charge - and in your application at about 170 mA max the drop will be very low. .  

The 1N400x will drop about 0.7V at full current (1A) but maybe 0.4 at full charge so in yout 170 mA max system it will work OK if Vpv = 6V LOADED in full sun.

Smaller capacity AA NimH are more robust and more able to withstand trickle charging. 1600 mAh AA are robust. 1600 mAh AAA are not.  

If Eneloop are available they will work well - they keep nearly full charge for long periods.