Didymos is a binary near-Earth asteroid. It is the target of the DART and HERA space missions. The primary body, Didymos, rotates close to the spin at which it is expected to shed mass. The secondary body, Dimorphos, is a 140 meters moon that orbits the primary body in about 12 hours. Here we investigate the possible origin of Dimorphos. Using 1D models of ring/satellite interactions, we study the evolution of material lost from Didymos' surface and deposited as a ring at its equator. We find that due to viscous spreading, the ring spreads outside the Didymos' Roche limit forming moonlets. A fraction of the mass will form Dimorphos and a set of objects near the Roche limit, while most of the ring's mass falls back on Didymos. To match the properties of today's Dimorphos, the total mass that must be deposited in the ring is about 25% of Didymos' mass. It is possible that a fraction of the material travelled several times between the ring and the surface of Didymos. The models produce an orbit similar to that observed for a Didymos tidal parameter k 2 /Q ≤ 10 −5 . If the ring deposition timescale is long (≥ 10 2 yr) (so the material flux is small) Dimorphos could be irregularly shaped as it forms from the collision of similar-sized satellitesimals. However, the top-shape of Didymos is expected to be achieved due to a fast spin-up of the asteroid, which would result in a short deposition timescale ( yr). In that case, the satellite would form from progressively accreting material at the Roche Limit, resulting in an ellipsoidal Dimorphos constructed of small pieces with sizes of the order of meters, which is apparently in agreement with the recent images of Dimorphos obtained by DART mission.keywords can be removed