Study of interaction between two oppositely charged polyelectrolytes and formation of polyelectrolyte complexes