That is a very good question as in fact with mass so compressed one must expect that it will explote to become another form of energy, it is again a consequence to that supposition of Einstein to have considered "that gravitation occupies an exceptional position with regards to other forces, particularly the electromagnetic forces", the same thing with the big bang, another consequence of that opinion regarding the exceptional position of the weakest force of the universe.
Even though photons have no mass, they are still affected by gravity. That's how we can see black holes - by the way they distort the light going near them. The reason nothing can escape a black hole is because within the event horizon, space is curved to the point where all directions are actually pointing inside. A black hole is a region where space-time is so curved that every possible path which light could take eventually curves and leads back inside the black hole. As a result, once a ray of light enters a black hole, it can never exit. For this reason, a black hole is truly black and never emits light. If its mass collapses into an infinitely small point, a black hole is born. Packing all of that bulk many times the mass of our own sun into such a tiny point gives black holes their powerful gravitational pull.Light is curved by a gravitational field. Time slows down in the presence of gravity, the affect of time slowing bends the light. In a black hole the gravity is so great light cannot escape. A black body absorbs all light/radiation in its reach. According to basic laws of physics, the more energy a body absorbs the more it can emit. Therefore, a black body absorbs all energy directed at it and also emits all energy that's been absorbed. Black holes are regions in space-time where gravity's pull is so powerful that not even light can escape its grasp. A black hole is a region where space-time is so curved that every possible path which light could take eventually curves and leads back inside the black hole. As a result, once a ray of light enters a black hole, it can never exit. For this reason, a black hole is truly black and never emits light. While it is true that photons have no mass, it is also true that we see light bend around sources with high mass due to gravity. This is not because the mass pulls on the photons directly, but instead because the mass warps the space-time through which the photons travel. Imagine a bowling ball on a mattress. Light also travels along geodesics, and so paths of light are also curved by gravitational force, despite the light not having any mass. Even though photons have no mass, they are still affected by gravity. That's how we can see black holes - by the way they distort the light going near them. The reason nothing can escape a black hole is because within the event horizon, space is curved to the point where all directions are actually pointing inside. While it is true that photons have no mass, it is also true that we see light bend around sources with high mass due to gravity. This is not because the mass pulls on the photons directly, but instead because the mass warps the space-time through which the photons travel. Imagine a bowling ball on a mattress.
There is though another point of view quite different from that Einstein:
“The present universe, the ashes of that explosion, is a strange one, as cosmology describes it. Most of it is dark matter, exotic particles that can never be observed. It is dotted by black holes, which suck in streams of dying stars, and it is threaded by cosmic strings, tears in the fabric of space itself. Our universe's future, cosmologists tell us, is grim: it is doomed either to end in a spectacular Big Crunch, collapsing into a universal black hole, or to expand and decay into the nothingness of an eternal night.
This striking cosmic vision, built up over the past twenty-five years by hundreds of theoreticians and explained in dozens of books, has sunk deeply into popular consciousness. Many have pondered what meaning life can have in a universe doomed to decay, unspeakably hostile and alien to human purposes.
Without doubt, the current concept of the universe is fantastic and bizarre. Yet despite the efforts and firm beliefs of so many cosmologists, it is also almost certainly wrong.
The validity of a scientific concept is not determined by its popularity or by its support among the most prominent scientists of the day. Many a firmly held doctrine, from the geocentric cosmos of Ptolemy to the phlogistic theory of heat, has enjoyed the nearly unanimous support of the scientific community, only to be swept away later.”
No, Gravity acts on objects having a non-zero mass only. Even though photons have no mass, they are still affected by gravity. That's how we can see black holes - by the way they distort the light going near them. The reason nothing can escape a black hole is because within the event horizon, space is curved to the point where all directions are actually pointing inside. Light is curved by a gravitational field. Time slows down in the presence of gravity, the affect of time slowing bends the light. In a black hole the gravity is so great light cannot escape. A black body absorbs all light/radiation in its reach. While it is true that photons have no mass, it is also true that we see light bend around sources with high mass due to gravity. This is not because the mass pulls on the photons directly, but instead because the mass warps the space-time through which the photons travel. Imagine a bowling ball on a mattress. Light also travels along geodesics and so paths of light are also curved by gravitational force, despite the light not having any mass. If there was a way (there isn't; special relativity prohibits it) to observe a photon at rest, you would find it mass less. All the relativistic mass of the photon comes from its energy. In particle physics when we say mass, we usually refer to the rest mass. This is why we usually say that photons are mass less. That's where light's duality as both a wave and a particle comes into play. Unlike a particle, whose momentum is related to its mass, a wave's momentum comes solely from its motion, meaning that it can carry momentum even without mass. The reason nothing can escape a black hole is because within the event horizon, space is curved to the point where all directions are actually pointing inside. The escape velocity from within a black hole's event horizon is faster than the speed of light, hence light cannot go at that speed and thus cannot escape. It's well known that light bends. When light rays pass from air into water, for instance, they take a sharp turn; that's why a stick dipped in a pond appears to tilt toward the surface. Out in space, light rays passing near very massive objects such as stars are seen to travel in curves. Even though photons have no mass, they are still affected by gravity. That's how we can see black holes - by the way they distort the light going near them. The reason nothing can escape a black hole is because within the event horizon, space is curved to the point where all directions are actually pointing inside. Light rays that pass close to the black hole get caught and cannot escape. Therefore, the region around the black hole is a dark disk. Light rays that pass a little further away don't get caught but do get bent by the black hole's gravity. This makes the star field appear distorted, as in a funhouse mirror.