While in general one cannot expect density of Lipschitz mappings (as pointed out by Nik WeaverNik Weaver), the following classical result is in the positive direction. You can find a proof in Heinonen's book Lectures on analysis on metric spacesLectures on analysis on metric spaces:
Theorem. If $f:X\to\mathbb{R}$ is a bounded and uniformly continuous function on a metric space, then there is a sequence of Lipschitz continuous functions $f_i:X\to\mathbb{R}$, $i=1,2,3,\ldots$$i=1,2,3,\dotsc$, such that $f_i\to f$ converges uniformly on $X$.
$X$ can be any metric space and compactness is not required. For that reason the argument based on the Stone-WeierstrassStone–Weierstrass theorem mentioned in some comments cannot be applied here.