A rock consists of minerals, sometimes of other rock pieces/fossils or a glass.
Minerals are the small particles that are visible in most rocks.
Rocks are divided in three major groups: igneous, sedimentary and metamorphic.
Igneous are formed by volcanic activity. There are divided in an intrusive igneous rocks and an extrusive igneous rocks The first ones are formed from molten magma under the surface, the others are formed from lava above the surface. They formed when lava/magma cools down. One of the keys for their identification is the grain size. The extrusive rocks have smaller grain size than intrusives. The main types are obsidian, granite, basalt, and andesite porphyry.
Sedimentary are formed from sediments under the pressure from new layers above the older layers. Here we have different subgroups as well, they are: clastic, chemical, biochemical and organic. They can be recognised by their fine grain sizes, "sandy" texture, and by the layers. These are the only rocks that may contain fossils.
Metamorphic rocks are formed from igneous and sedimentary due to changes are caused by pressures and temperatures. The difference is that metamorphics is reformed in a solid state.Opposed to igneous rocks they don't melt. Due to a compression and stretching, some of the rocks may become foliated.
Yes, minerals are classified by their composition (chemical), they can be divided into two general classifications - rock forming minerals and ore minerals (precious).
Rock forming minerals are the non-metallic minerals and they are the vast majority of all minerals: quartz, calcite, aragonite, strontianite, etc.
Metal ore minerals are a precious minerals and they are worth some money. Ore minerals contain gold, silver, copper, nickel, zinc and many more.