You can obtain a divorce, either by filing a contested divorce petition , or if your husband consents, by mutual consent. A contested divorce may take around 2/3 years for disposal, whereas, a mutual consent divorce may take about 6 month.
Furthermore, with respect to custody of your child, your child is minor and that you need to file a petition for the custody of the children. Section 6 of The Hindu Minority and Guardianship Act states that the ‘natural guardian of a Hindu minor, in respect of the minor’s person as well as in respect of the minor’s property in the case of a boy or unmarried girl is the father, and after him, the mother, provided that the custody of a minor who has not completed the age of five years shall ordinarily be with the mother.
So, normally, courts do allow custody of a 2 year daughter to the mother. However for appointment of declaration of any person as guardian, the court shall consider the welfare of minor. The welfare of the child is determined neither by the economic affluence nor a deep mental or emotional concern for the well being of the child.
The answer depends on the balancing of all these factors and determining what is best for the child’s total well being and thus there are numerous occasion wherein Supreme Court has allowed father to retain the custody of child.