Imagine the people sitting at a table, talking pleasantly. The conversation is travelling from one person to the other, literally over their cups of tea. The use of "over" indicates some kind of transit.
"With a cup of tea" sounds as if the tea is something on the side, not in front of the chatty people, and not really participating in the whole image. Same is if you said "by a cup of tea".