The public key system Ellis contrived involved three codes. One is used by the sender of information - the recipient uses the other two.
We start with the recipient, who has a unique random number available publicly, akin to one in the phone book.
Such a figure is available to the sender, who uses it with a private number unique to them, to scramble the message. That can be unscrambled only by the recipient, whose second number, privately held, is the unique key to unlocking any code generated with the public one. The larger the figures in the codes, the more difficult they are to crack.
Happily, for those not devoted to mind-stretching sums, the calculations take place automatically within the innards of computers. Appreciation of the mathematics is probably confined to those who get their kicks from algorithms, although the basic process is relatively straightforward.