An acid is a substance that forms hydrogen ions, H+, when it dissolves in water. Hydrogen chloride, HCl, dissolves to give H+ ions and chloride ions. Sulfuric acid and nitric acid also form hydrogen ions in water. The hydrogen ions are free in the solution; they are not still attached to the molecule.
Solutions of alkalis contain hydroxide ions, OH-. Sodium hydroxide, NaOH, dissolves to give sodium ions and hydroxide ions. An alkali is a base that dissolves in water, so it is a soluble base.
It is the ions that make a solution behave as an acid or an alkali. All acids share the hydrogen ion, and all alkalis share the hydroxide ion. In both cases the ions are free to move around in the solution.