According to Einstein's theory of general relativity, mass and energy curve or bend the fabric of spacetime. This curvature of spacetime is what we perceive as gravity.
In the theory of general relativity, spacetime is treated as a four-dimensional continuum, where three dimensions represent space, and the fourth dimension represents time. Massive objects, such as planets, stars, or even black holes, create a dent or curvature in this four-dimensional spacetime.
Think of spacetime as a two-dimensional rubber sheet. If you place a heavy object like a bowling ball on the sheet, it creates a depression or curvature in the sheet. If you were to roll a smaller object, like a marble, near the bowling ball, it would be affected by the curvature and move towards the bowling ball. Similarly, mass and energy cause a curvature in spacetime, and other objects, like planets or satellites, move along the curvature created by more massive objects.
This warping of spacetime is what we perceive as gravity. Objects with mass follow the curvature of spacetime and move in a curved path around more massive objects. The larger the mass of an object, the greater the curvature it creates in spacetime, and the stronger its gravitational pull.
It's important to note that the concept of mass bending spacetime is a simplified explanation. In reality, it is the presence of mass-energy that causes the curvature, and objects with mass and energy move along geodesics (curved paths) in this curved spacetime.