That’s the entire use case. And, for keeping a pair, the convention is to use -, e.g. X-Y.
Also, there are predicates that are designed to work with lists of pairs, e.g. keysort/2 and group_pairs_by_key/2.
For example:
?- setof(X-Y, (between(1,5,X), Y is X**2), Pairs), pairs_values(Pairs, Squares).
Pairs = [1-1,2-4,3-9,4-16,5-25],
Squares = [1,4,9,16,25].
BTW, this might help you understand how the “syntactic sugar” of operators is defined:
?- current_op(A,B,+).
A = 200,
B = fy ;
A = 500,
B = yfx.
?- op(500, yfx, foo). % define `foo` as an operator, same as `+`.
true.
?- X = 2 foo 3 .
X = 2 foo 3.
?- 2 foo 3 = foo(2,3).
true.
?- 2 foo 3 + 4 = +(foo(2,3),4).
true.
And if you want to see how operators have been processed syntactically, use write_canonical/1:
?- write_canonical(2 foo 3 + 4).
+(foo(2,3),4)
true.