She became friends with Tom at the party.

Literal

She [topic-は] party [at-で] Tom [with-と] friend [to-に] became.

友達になる ('become friends') uses the change-of-state pattern noun+になる, with the relationship as the new state. The companion particle と marks Tom as the partner in this becoming — the と of joint or reciprocal action, distinct from the quotative と and the listing と. This same particle structure underlies 結婚する ('marry') with と (誰々と結婚する, 'marry someone'), 別れる ('part with'), 話す ('speak with'). Note that 友達 stays singular even though both parties become friends — Japanese doesn't pluralise the noun the way English does.