For an azeotropic binary mixture, the number of phases is 2 and number of components are 2. So, according to Gibbs phase rule, the number of degrees of freedom should be 2. But, the right answer is 1. Can someone explain this?
Gibbs' phase rule simply counts the number of variables required to specify the system and the number of relationships between these variables (constraints). Any failure of Gibbs' phase rule is symptomatic of additional variables or constraints that have not been taken into account.
This system is generally specified by four variables, the mole fraction of one species in the liquid phase, $x$, the same in the gas phase, $y$, the pressure $P$, and the temperature $T$. Equilibrium of the liquid and gas phases in both species provides two constraints. The specification of an azeotrope, for which $x = y$, provides a third constraint, as has been mentioned in the comments. One degree of freedom remains.
The Gibbs Phase rule can be applied to a P-T thermodynamic diagrams for pure substances. On any such of diagram, each point represents a state of the material. Once the point has been located, all other thermodynamic properties can be read off.
For a single phase, the required point can fall anywhere on the region of the plane representing this phase. Thus, two coordinates are needed to specify a point within that part of the plane. For example the horizontal and vertical axis values, T and P, can be given. (F=2)
A two phase region on a P-T is represented by a curved line. Thus, to specify a point on this curve only one additional coordinate, either T or P is needed. (F=1)
The triple point is represented by a single point. No additional information, neither T nor P is needed. (F=0)