Same marginals, different joints

Construct two processes that are Bernoulli(p) at every time and that have different joint distributions at times 1 and 2. Compute \mathbb{P}(X_1=X_2) for each.

Let B\sim\mathrm{Bernoulli}(p) and set X_n=B for every n. Let Y_n be independent Bernoulli(p) variables. Each one-time marginal is Bernoulli(p). The joints at times 1 and 2 differ:

\mathbb{P}(X_1=X_2)=1, \qquad \mathbb{P}(Y_1=Y_2)=p^2+(1-p)^2.

The second probability is the chance that two independent bits agree, either both 1 or both 0.