When fuel burns, it combines with oxygen to form lighter gasses and heat. This is called combustion. The gasses expand rapidly since they are much less dense than the fuel itself. When the gunpowder in a firecracker burns, the expanding gasses have nowhere to go, so the sudden increase in pressure destroys the casing of the firecracker. The weak seal between the casing and the bullet in a round of ammunition allows the expanding gasses to force the bullet away from the casing and out of the barrel of the gun. It also forces the gun away from the site of the combustion, which causes the kick when a gun is fired. Combustion engines burn fuels to create motion, but where gas engines use that combustion to move complex machinery, rockets use their power directly. In a rocket engine, as with a bullet, the force created by the combustion of fuels is focused in one direction; it is focused toward the opening of the barrel in a gun and toward the opening at the bottom of the rocket in a rocket engine. Rather than using the combustion to force a projectile away from the expanding gasses, a rocket engine uses that force to propel itself away from the expanding gasses, just like the kick of a rifle.
Rocket propellent is a combination of fuel and oxidizer. Fuel needs oxygen to burn. Any oxygen present in the air inside of a rocket engine is quickly burned up during combustion. Rocket engines use oxidizers, substances that release oxygen as the fuel burns, to provide a constant source of oxygen. The two main types of fuel used in rocket propellent are solid and liquid.
Solid propellents are lightweight and stable at room temperature. They are designed with a hollow core that allows the expanding gasses to escape as the fuel burns. The oxidizer is incorporated into the propellent mixture. Solid fuels cannot be stopped once they are ignited. These engines burn until their fuel is expended. The two solid rocket boosters on either side of the space shuttle's external tank provide the main source of thrust during liftoff. Due to their stability and simplicity, solid propellents are also used in commercial model rockets.
In a rocket that uses liquid propellents, the fuel and the oxidizer are stored in separate tanks. The two liquids are allowed to mix, often being sprayed together in the combustion tank, and either ignite on contact or are ignited by an external ignition source, depending on the type of propellent being used. These fuels are less stable than solid fuels --- liquid oxygen, a common oxidizer, must be kept at a very low temperature to keep it in a liquid state. The combustion of liquid propellent can, however, be adjusted or even stopped before the fuel is expended. The large external tank to which the space shuttle is attached during launch carries the liquid propellent that the shuttle uses during liftoff.