The boundary value problems for the Lyapunov equation in the resonant (irregular) case in Banach and Hilbert spaces, when the solution of the equation does not exist for all right-hand sides and its uniqueness may be violated, have been investigated. The conditions for bifurcation and branching of solutions in linear and nonlinear cases, including with a moving right end of the segment on which the corresponding boundary value problem is considered, are found.