TheI agree with Tom Goodwillie that it is immediate from the definitions that the unknotting number is well-defined. I think that what might be tripping you up is being taught that “knot invariants” are really diagram invariants that are invariant under the Reidemeister moves. That makes invariants like this one that cannot be computed from a given diagram in a straightforward way confusing.
Anyway, on to its origins. The earliest reference I know about is
Wendt, H. Die gordische Auflösung von Knoten. Math. Z. 42, 680–696 (1937)
It's been a very long time since I read this paper (and my German is mediocre, so it would take some effort for me to re-read it today), so I can't remember if it references anything else.
As evidence that this is the original source, Reidemeister's classic book on the subject references Wendt's paper when it introduces the unknotting number. See the beginning of Chapter 2.