[guided]The previous steps give two facts. First, the lost set $D$ is the disjoint union of the sets $D_p$ over primes $p\in P$ with $z_1\leq p<z_2$. Since all sets involved are finite, cardinality is additive over this disjoint union:
\begin{align*}
\#D=\sum_{p\in P,\ z_1\le p<z_2}\#D_p.
\end{align*}
Second, for each such prime $p$, the identification step proved that $\#D_p=S(A_p,P,p)$. Substituting this into the preceding equality gives
\begin{align*}
\#D=\sum_{p\in P,\ z_1\le p<z_2}S(A_p,P,p).
\end{align*}
The first step also proved that $S(A,P,z_1)-S(A,P,z_2)=\#D$. Combining the two equalities yields
\begin{align*}
S(A,P,z_1)-S(A,P,z_2)=\sum_{p\in P,\ z_1\le p<z_2}S(A_p,P,p).
\end{align*}
Rearranging this finite equality gives
\begin{align*}
S(A,P,z_2)=S(A,P,z_1)-\sum_{p\in P,\ z_1\le p<z_2}S(A_p,P,p),
\end{align*}
which is the claimed Buchstab decomposition.[/guided]