Why does professor prohibit me talking to people?
There are several possibilities for this behaviour. 


You're good, he knows that, and the collaboration with the other research group is more formal than you may know (maybe they are in the same funded project because it was the only way to be funded, while the two groups may be in competition). In this case, he doesn't want you to go “behind enemy lines”.
You're not the one he was looking for, he recently discovered that. He is very close with the other group and he don't know how to tell you that you are not a good fit for his group and relatives. So instead, he changed what he said in order to make it unacceptable for you, hoping that you will leave, and that you will also not go to the other group.
He's not reliable, he had a weird idea of what is a student.


By the way, except if you are a recognized genius, this is unlikely that the other team will accept you if they are close to your current advisor and want to stay that way.

In all three cases, only one option: run far away.