The captain put his arms around the girl’s shoulders. They talked about their wedding, three months ahead. He had not, after all, ever broken their engagement.
Dose it mean: They talked about their wedding that happened three mounths ago
The wedding was planned to happen three months in the future.
In English† the past is metaphorically said to lie "behind" the speaker and the future is said to lie "in front of" the speaker, so forward and ahead—both designating the spatial or temporal direction you are facing—refer to the future. The captain and the girl plan to marry three months after the event currently being narrated.
† And many other languages, but not all. Speakers of Aymara, for instance, think of the past as lying in front of them, because it is "visible", while the unknowable future lies behind them.
Months is spelled months, not mounths.
In this quote, they are talking about their wedding that is going to happen in three months. It is three months into the future.
If they were talking about three months ago, it would say, "three months behind."
The definition of ahead can mean in the future:
- in, into, or for the future
Another way to say your excerpt with the same meaning:
The captain put his arms around the girl’s shoulders. They talked about their wedding, to happen in three months. He had not, after all, ever broken their engagement.
The captain and the girl are engaged and never stopped being engaged (never broke their engagement). They will get married in three months. Now they are talking about their upcoming wedding.