The pH of a solution depends on the concentration of ions in it. In an acidic solution the ions that matter are hydrogen ions, H+. The higher the concentration of hydrogen ions, the lower the pH. A very acidic solution, such as concentrated hydrochloric acid, has a lot of H+ ions in every cubic decimetre and a pH close to 0.
In an alkaline solution the ions that matter are hydroxide ions, OH-. The higher the concentration of hydroxide ions, the higher the pH. A very alkaline solution has a lot of OH- ions and a pH close to 14.
If you dilute an acid with water, the concentration of hydrogen ions falls, so the pH rises towards 7. Diluting an alkali lowers its pH towards 7 in the same way.