What exactly is a formula in set theory? I've taken a look at this: Set theory formula
But I'm still a little confused. Is the formula supposed to take x, y, z as input and produce "TRUE" as an output? Are all set theory formula's TRUE?
 A: A formula is an expression of the language of set theory built up acoording to the rules of the syntax. 
Examples : $∃y \ ∀x \ ¬(x ∈ y), ∀x \ ¬(x ∈ \emptyset)$.
A formula can be a sentence, i.e. without free variables (like the two previous examples) ore an open one, like e.g. : $(x∈y)$.
A sentence has a definite truth value : $∀x \ ¬(x ∈ \emptyset)$ means "the empty set has no elements" and it is true in set theory.
An open formula, like $(x∈y)$ has not a definite truth value; its truth value depends on the "reference" assigned to the variables.
Consider some simple arithmetical examples : $\forall n (n \ge 0)$ is true in $\mathbb N$.
Consider $(n > 0)$ instead : it is false if $n$ denotes $0$ and is true otherwise.

For a formal definition, see the post : In Mathematical Logic, What is a Language?
A: Put simply in the language of set theory we start with atomic formulas
$$(x\in y)$$
or
$$(x=y)$$
where $x$ and $y$ are variables.
Then we expand the definition of formulas to so that it is closed under $$\neg(\cdot)$$ and $$(\cdot)\wedge(\cdot)$$ and $$(\exists x)(\cdot)$$ where $x$ is a variable.
Then we introduce the following notations.
$$(\varphi\vee\psi)\equiv\neg(\neg\varphi\wedge\neg\psi)$$
$$(\varphi\Rightarrow\psi)\equiv\neg\varphi\vee\psi$$
$$(\varphi\Leftrightarrow\psi)\equiv(\varphi\Rightarrow\psi)\wedge(\psi\Rightarrow\varphi)$$
$$(\forall x)\varphi\equiv\neg(\exists x)\neg\varphi$$
We take variables, punctuations, $=$, $\in$, $\neg$, $\wedge$, $\exists$ as primitive notions. That is to say, they are undefined symbols which are informally trying to capture the notion of variables, punctuations, equality, membership, negation, conjunction, existential quantifier. Establishing a collection of axioms is how we try to capture desired notions.
Let me speak in the language of set theory:
$$(\exists x)(\neg(x=x))$$
What I just said is false because of established axioms of set theory; most popular being $\mathsf{ZFC}$.
Let $\varphi$ be an arbitrary formula. Then certain variables within $\varphi$ are "free." We typically denote those variables by writing $\varphi(x_1,\ldots,x_n)$ instead of simply $\varphi$.
