The AH means Amp Hours and is a measure of how much electricity the battery can store.
Thus if the 12AH and 15AH batteries were connected to THE SAME device (one after the other) the 15AH battery would run the device for longer than the 12AH battery.