Having trouble reconciling perfect and totally disconnected

It's hard for me to make sense of a perfect, totally disconnected space.

Mainly, here's where I am running into a wall.

If the space is totally disconnected, then a set $\{x,y\}$ is not connected, because the connected components are singletons.

But, how can I separate it? The seemingly only way is $\{x\} \cup \{y\}$, but since the space is perfect, singletons cannot be open!

How do we form a separation on a two-point set in such a space?

Thank you.

I think you're mixing up set with topological space. If a topological space $X$ is totally disconnected, then yes a set $\lbrace x,y\rbrace \subset X$ is not connected, but that doesn't necessarily mean that the open sets which separate $\lbrace x,y\rbrace$ need to be subsets of $\lbrace x,y\rbrace.$ Being totally disconnected guarantees the existance of open sets $U,V \subset X$ such that $x\in U,y\in V, U\cap V = \emptyset,$ and $\lbrace x,y\rbrace \subset U\cup V.$ Being perfect means that $U\cap (X\setminus \lbrace x \rbrace)\neq \emptyset$ and $V\cap (X\setminus \lbrace y \rbrace)\neq \emptyset,$ and those two properties are not mutually exclusive. It does, however, say that you can't have a $2$-point topological space which is perfect and totally disconnected for the reasons you stated.
First off, if $x$ and $y$ are two different points in any Hausdorff space $X,$ then the two-point subspace $\{x,y\}$ disconnected; it doesn't matter if $X$ is connected or disconnected or totally disconnected. So your don't have to look at anything as exotic as a totally disconnected perfect space, you will have the same problem with a connected perfect space such as the real line: the subspace $\{0,1\}$ of $\mathbb R$ is disconnected.
Yoiur problem is that you don't understand the subspace topology. All four subsets of $\{0,1\}$ are open in the relative topology of $\{0,1\}$ as a subspace of $\mathbb R,$ but only one of them (the empty set) is open in $\mathbb R.$