what is best way to model many-to-many relationship?
lets say we have a two classes , Team and Player
It's worth to distinguish the API feel from actual implementation.
While it makes sense for both classes to expose such a collection (e.g. get*List()), they don't neccessarily have to hold the instance of the collection.
I suggest you create a League
class or something alike, that holds some sort of a private player-team mappings dictionary. Additions to those 'collections' thorough the Team/Player instance, should call internal methods on the League
instance to update the mappings. This way, you keep updates atomic (as Andrey suggested) and error free.