A giant impact as the likely origin of different twins in the Kepler-107 exoplanet system