He found out that his wife had got married before and was divorced before consummation of the marriage, but she had spent time alone with her ex-husband
Question

After I got married, I found out that my wife had been married before and was divorced, but her ex-husband did not consummate the marriage with her, but he was alone with her more than once. Now problems have arisen three weeks after getting married, and the problem has led to her family asking for divorce. Should they return to me everything that I gave them?
Praise be to Allah.Firstly:
If a woman is divorced after being alone with her husband and before consummation of the marriage, then she is still a virgin, and she may get married as any virgin may get married. This has been stated by a number of the fuqaha’.
It says in Durar al-Ahkam (1/336): If a woman gets divorced after being alone with her husband in the sense defined in fiqh, and she is still a virgin, or she gets divorced before the marriage is consummated, then she may get married like other virgins, even though the ‘iddah is required of her, because she is a virgin in a real sense and still has haya’ (shyness). End quote.
In al-Fatawa al-Hindiyyah (1/306), it says: Our companions [in the Hanafi madhhab] regard being alone with the husband in the sense defined in fiqh as being equivalent to intercourse, in the case of some rulings but not others… but being alone with the husband is not equivalent to intercourse with regard to ending virginity, even if the husband is alone with his virgin wife then divorces her (without consummation of the marriage). In that case she may get married as a virgin. End quote.
It says something similar in Bulghat as-Salik by as-Sawi (4/354) and al-Insaf (8/284).
If the cause of the dispute between you is that you think that they deceived you in this marriage, then the matter should be referred to the shar‘i court to decide about the case.
Secondly:
If the wife asks for divorce without there being any shortcoming on the part of the husband that would be a reason to ask for divorce, then he may refuse to divorce her but may separate from her by means of khul‘, on condition that she returns the mahr to him.
Please see the answer to question no. 26247 .
And Allah knows best.