Yes. A locally finite example is given as follows. Let $I$ be a totally ordered set. For a field $F$, let $G(I,F)$ be the group of (infinite) square matrices indexed by $I\times I$ with entries in $F$, that are upper triangular with diagonal 1 and finitely many nonzero entries above the diagonal. It is not hard to show that $I$ is generated by the $e_{ij}(r)$ for $i<j$ and $r\in F$ (matrix differing from identity only at $(i,j)$, where entry is $r$).
Suppose that $I$ has a minimum $0$ and a maximum $1$ with $0\neq 1$.
The elementary matrix $e_{01}(1)$ is central, so the center is nontrivial. If in addition $I\smallsetminus\{0\}$ has no lower bound and $I\smallsetminus\{1\}$ has no upper bound, the $G(I,F)$ is perfect. If $F$ is a field of characteristic $p$, then $G(I,F)$ is a locally finite $p$-group. If both $F,I$ are countable, then $G(I,F)$ is countable.
Hence, for $I=[0,1]\cap\mathbf{Q}$ and $F=\mathbf{Z}/p\mathbf{Z}$, $G(I,F)$ answers the question.
Note: I guess there also exist (less elementary) finitely generated examples, and probably even of finite exponent. A relevant reference could be (MR link, Russian version) Ashmanov, I. S.; Olʹshanskii, A. Yu.
Abelian and central extensions of aspherical groups. (Russian)
Izv. Vyssh. Uchebn. Zaved. Mat. 1985, no. 11, 48–60, 85. English translation: Soviet Math. (Iz. VUZ) 29 (1985), no. 11, 65–82. [Edit: according this answer by Mark Sapir there are many Tarski monsters with nontrivial (even infinite) $H_2$ (I hope Mark can give more details where exactly this is proved and if, as we can expect, this can provide central extensions of finite exponent).]