I'm considering the Wikipedia definition of a Boolean lattice. Is there any restriction on the number of elements a Boolean lattice or Boolean algebra have? (I'm asking because, say, for fields the restriction is that they must have prime power order)
Also, say I want to create a 10 element Boolean algebra? What would be an example or algorithm to create it? (For groups it is easy. I could just consider $\Bbb Z_{10}$ but I can't come up with an example for a 10 element Boolean algebra)
Yes: a finite Boolean algebra must have $2^n$ elements for some $n\in\mathbb{N}$ (and of course any power of $2$ is attainable, by taking the power set of an $n$-element set). In fact, every finite Boolean algebra is isomorphic to the power set of some set. As a sketch of a proof, if $B$ is a finite Boolean algebra, let $S\subset B$ be the set of atoms (minimal nonzero elements). Then the map taking $b\in B$ to the set of $s\in S$ such that $s\leq b$ is an isomorphism from $B$ to $P(S)$.
For infinite Boolean algebras, any cardinality is possible. For instance, if $S$ is any infinite set, the Boolean algebra of subsets of $S$ that are either finite or cofinite has the same cardinality as $S$.