The universal introduction rule
requires that x in the premise is a free variable. (In addition, it must not be free in any open assumption of P(x).) In your derivation, is a constant, so you can't apply this rule to derive .
On the other hand, and are inconsistent and therefore do imply any formula, including : one can conclude any formula directly from , which is obtained from and . However, that arbitrary conclusion would still have an open assumption . In contrast, the proof above takes care to close the temporary assumption .