The following definition should be standard, but let me state it just in case there is some ambiguity:
If $\mathscr{L}$ is a set of subsets of a set $X$ that is closed under finite unions and intersections and contains $\varnothing,X$ (or more generally, if $\mathscr{L}$ is a distributive lattice with top and bottom elements), let us say that $\mathscr{F} \subseteq \mathscr{L}$ is a filter in $\mathscr{L}$ provided it contains $X$ (the top element), is closed under finite intersections (meets), and is an up-set (meaning that if $A \subseteq B$ with $A \in \mathscr{F}$ and $B \in \mathscr{L}$ then in fact $B \in \mathscr{F}$). Let us say that such a filter is proper iff it does not contain $\varnothing$; and that it is an ultrafilter iff it is proper and maximal for inclusion among proper filters.
If $\operatorname{Ult}(\mathscr{L})$ denotes the set of ultrafilters in $\mathscr{L}$, then for every $A\in\mathscr{L}$ we define a set $Z(A) := \{\mathscr{U}\in\operatorname{Ult}(\mathscr{L}) : \mathscr{U} \ni A\}$ of ultrafilters containing $A$ as an element. It is almost trivial that $Z(A\cap B) = Z(A) \cap Z(B)$, and it is also true, though slightly less trivial, that $Z(A\cup B) = Z(A) \cup Z(B)$ (sketch of proof: the inclusion $\supseteq$ is clear, so let us see $\subseteq$: if $\mathscr{U} \ni A\cup B$ and $\mathscr{U} \not\ni A$ then the filter generated by $\mathscr{U}$ and $\{A\}$ contains $\varnothing$, so $A\cap U = \varnothing$ for some $U\in\mathscr{U}$, and then $\mathscr{U} \ni (A\cup B)\cap U = B\cap U \subseteq B$ so $\mathscr{U}\ni B$).
In particular, the $Z(A)$ form a basis of closed sets for a topology on $\operatorname{Ult}(\mathscr{L})$ called the Zariski topology. (Digression: note that they also form a basis of open sets for another topology, the Stone topology; I mention this in passing, because this confused the hell out of me: part of the confusion comes from the fact that, if $\mathscr{L}$ is actually a Boolean algebra, — e.g., if we consider all subsets of $X$, or more generally the clopen subsets of a topological space $X$, — then the complement of $Z(A)$ is $Z(X\setminus A)$ so the two topologies coincide.)
As an example, if $X$ is a topological space and $\mathscr{Z}$ is the lattice of zero-sets of continuous real-valued functions on $X$ (“z-sets”), then $\operatorname{Ult}(\mathscr{Z})$, with its Zariski topology, is the Stone-Čech compactification of $X$ (Gillman & Jerison, Rings of Continuous Functions (1960), points (a) and (b) in the proof of theorem 6.5).
This example has long bothered me because z-sets seem to make a fairly incongruous appearance, and I wondered why we don't take closed sets instead, which seem more “fundamental”, and what happens if we do. Let me ask precisely that:
Question: if $X$ is a topological space, $\mathscr{C}$ is the lattice of closed sets of $X$, can we better describe the space $\operatorname{Ult}(\mathscr{C})$ of ultrafilters in $\mathscr{C}$, endowed with its Zariski topology? Does it have a name? What is “wrong” with it that makes it less interesting than the Stone-Čech compactification?
(Note that if $X$ is metric, then closed sets and z-sets coincide, so the above space is the Stone-Čech compactification.)
Maybe assume that $X$ is $T_1$, which ensures that we have a continuous map $X \to \operatorname{Ult}(\mathscr{C})$ taking $x\in X$ to the set of $F \subseteq X$ closed such that $F\ni x$.
Remark: For the description of the space of ultrafilters of open sets (with the Stone topology), see this answer on MSE, where I prove that it is the “Gleason space” of $X$.