The differential equation governing the simple pendulum is
m\frac{d^2\theta}{dt^2}= Lsin(\theta)
where m is the mass of the pendulum, L the length of the pendulum (from the pivot to the center of mass), and \theta is the angle the pendulum makes with the vertical.
That does not involve the variable t explicitely so we can use "quadrature". let y= d\theta/dt so that d^2\theta/dt^2= dy/dt and, by the chain rule, that is equal to dy/dt= (dy/d\theta)(d\theta/dt)= y(dy/d\theta).
That is, the equation can be written as
my\frac{dy}{d\theta}= L sin(\theta)
which is a separable equation:
y dy= (L/m)sin(\theta)d\theta
and, integrating,
\frac{1}{2}y^2= \frac{L}{m}cos(\theta)+ C
Solving for C gives the formula you have.
Now, as for graphing it, look at four separate possibliites for C. The left side, being a square, cannot be negative while the largest (L/m)cos(\theta) can be is L/m. If C< -L/M, the right side is always negative so the equation cannot be satisfied. There is NO graph for C<-L/M.
If C= -L/M, then for \theta= (2n)\pi, that is, even multiples of \pi, (L/M)cos(\theta)- L/M= 0 but for all other values of \theta are negative so the graph is a series of points (2n\pi, 0). Those correspond to the pendulum hanging straight down. (Some textbooks show this on a cylinder with the angle going from 0 to 2\p so there is just one such point.) This is, of course, a stable equilibrium position.
If -L/M< C< L/M. then the righthand side will be positive for \theta 0 to where (L/M)cos(\theta)- C= 0 which will be between 0 and \pi. Of course, cosine is an even function so the same thing is true for y negative. That is, the graph will be a curve starting at (0, y) for some positive number y, then going down to (x, 0) for some x between 0 and \pi and exactly the same thing between 0 and (-x, 0). Further, since the left side is y^2, that same behaviour occurs below the \theta-axis. That symmetry produces a closed figure that looks like an ellipse or a circel (it is not either exactly). Those ovals are reproduced about every even multiple of pi.
Further, because y is the derivative of the angle, when y is positive, above the \theta axis, \theta is increasing so we might draw a small arrow to the right, and, below the \theta axis, \theta is decreasing so we might draw a small arrow to the right. The effect is to give a "motion" around the oval in a clockwise direction. That corresponds to the periodic motion with the pendulum swinging, with positive velocity, to the largest angle, then back the other direction. (In phase diagrams, closed paths are periodic motion.
If C= L/M, those Curves go all the way out to \pi and connect with the next set of curves. At each point ((2n+1)\pi, 0), we have four curves, two with arrows pointing toward the point, two with arrows pointing away from it. These correspond to the pendulum being swung with just enough initial speed to reach the "straight up" position and stopping there. That is, of course, an unstable equilibrium position. At that position, any slight jar might make the pendulum swing down in either direction.
Finally, if C> L/M those curves never go down to 0- when \theta= \pi (or any odd multiple of \pi, y= -(L/M)+ C, then increases again. Now the curves continue in both directions, above and below the axis, smoothly. Again, the "direction of motion", the arrows we put on each show motion to the right for y positive, to the left for y negative, now continuing in the same direction indefinitely. These correspond to swinging the pendulum hard enough that it gets to the top with non-zero speed and so continuse in the same direction. Since this equation represents no friction in the pendulum, it regains speed as it comes down and so just continues swinging in the same direction.