Hi, I'm newbie and I'm trying to drive solenoids through Pi. I'm not sure about the connection between Pi and Relay and also from Power source to relay and solenoids. Could you help me about these two doubts? Thank you
Your diagram scares me. Specifically, the 220V label. That potentially fatal voltage combined with inexperience ("newbie") is very risky. If a screw comes loose and line voltage comes into contact with something else, lots of dangerous things can happen. I work with electronics and still choose to purchase a commercial power relay that I can control with my Raspberry Pi. I'm sure you could find safer alternatives.
If you really do wish to continue with this risky design against all caution, you will also need to use the right relay. Please consult the 05VDC label on your blue relays. Those relays do not really work well with the Raspberry Pi, which has 3.3V GPIO, not 5V. Use a Raspberry Pi relay. Those are Arduino relays.