An annulment is more accurately termed a “declaration of matrimonial nullity” and does not actually nullify anything. Rather, the annulment process determines whether what may appear to be a valid marriage is actually a valid marriage or not. If it is determined that a valid marriage does not exist, then it is declared that the marriage is null—that a valid marriage never existed.
In his book Annulments and the Catholic Church, Edward Peters explains that an annulment is
A juridic determination that, at the time of the wedding, one or both parties to the marriage lacked sufficient capacity for marriage, and/or that one or both parties failed to give adequately their consent to marriage as the Church understands and proclaims it, and/or, in weddings involving at least one Catholic, that the parties violated the Church’s requirements of canonical form in getting married. (1-2)