Doesn't a function with constant modulus on the boundary of a bounded domain have constant modulus over the entire domain?

I'm having difficulties with a question from Complex Analysis (Gamelin). The question has been asked before, but I still have some difficulties with it. It asks to show that a function continuous on unit disk and its boundary and analytic on the unit open disk is a finite Blaschke product if its modulus on the boundary of the disk is one. The solutions I have read suggested that one divide the function by the finite Blaschke product with zeros identical to zeros of f. I first of all do not understand why f should have a finite number of zeros. Secondly, would it not follow by the maximum and minimum modulus principle that f has constant modulus on the entire disk since its maximum and minimum moduli on the boundary of the disk are one? Then, how can f acquire any zeros whatsoever? Am I misusing the max/min mod principle here?

As well, how does dividing the function by the finite Blaschke product with zeros identical to the zeros of the function help? The claim was that the function is now by the max mod principle constant (??). I still don't see how this follows.

Thank you!

1) If $f$ had infinitely many zeros in the disk, those would have a limit point. By continuity the value at such a limit point would be $0$ too. If $f$ has no zeros on the circle, the limit point is thus a non-isolated zero of the function. But an analytic function with a non-isolated zero is identically $0$.
2) If $f$ had no zeros in the disk and constant absolute value on the circle, it would indeed have have constant absolute value, and therefore would be constant. A function with zeros in the disk can have constant absolute value on the circle, the simplest example being $f(z) = z$.
• @MR1992: One of the hypotheses of the minimum modulus principle is that your function be nowhere zero; its proof boils down to "apply the maximum modulus principle to the holomorphic function $1/f$." Nov 28, 2012 at 21:45