Wikipedia has all the information you need to distinguish a folio-size book from a quarto, octavo, duodecimo... all the way to sixty-fourmo.
But it's easier to undersand if you visit Got Medieval and read "Why are [medieval] books so big?" He starts with the sheep and illustrates subsequent foldings of the skin with the resultant examples of books.
Then see this link re how the pages were laid out (the "imposition") for printing prior to folding.
Wikipedia notes that the terminology is only marginally related to modern printing techniques:
For example, a modern novel may consist of gatherings of 16 leaves, but may actually have been printed with 64 pages on each side of a very large sheet of paper. Similarly, the actual printing format cannot be determined for books that are perfect bound, where every leaf in the book is completely cut out (i.e., not conjugate to another leaf as in gatherings) and is glued into the spine. Modern books are commonly called "folio", "quarto" and "octavo" based simply on their size rather than the format in which they were actually produced, if that can even be determined. Scholarly bibliographers may describe such books based on the number of leaves in each gathering (8 leaves per gathering = octavo), even where the actual number of pages printed on the original sheet is unknown or may reject the use of these terms for modern books entirely.