Hello Bogdan,
this broschure should answer your questions:
http://www.deutsche-rentenversicherung.de/Allgemein/de/Inhalt/5_Services/03_broschueren_und_mehr/01_broschueren/02_international/weitere_abkommen_fremdsprachig/working_in_germany_no_contracting_states.html