With the heat death, the entire universe is at a uniform temperature. Because there is no temperature differences at any two points in the universe, no thermodynamic work is possible. Maximum entropy has been reached.
On the other end of the timeline, at the beginning of the universe, it began in a homogenous state as a dense primordial fireball.
The ‘Big Bang’ is the model for the formation of our Universe in which spacetime, and the matter within it, were created from a cosmic singularity. The model suggests that in the 13.7 billion years since the Universe began, it has expanded from an extremely small but incredibly dense and hot primordial fireball, to the enormous but cold and diffuse Universe we see around us today.
The theory that best explains the currently observed state of the universe is the Big Bang theory. This theory states that, in the beginning, the universe was all in one place. All of its matter and energy were squished into an infinitely small point, a singularity.
From a thermodynamic point of view, entropy would already be high. Why should this initial high entropy result in the work of creating galaxies, stars, and planets? Whether the universe was very small or very large, if temperature was uniform throughout it, it would not be possible to do any work. You can consider the initial singularity to already be at the thermodynamic heat death.
So, the problem of entropy exists in the initial state of the Big Bang as well. What would cause a high entropy state to expand the universe and perform work? This reason is unknown to cosmologists.