test: refactor: clarify the coins simulation
Summary:
Adds comments, slight refactor clarifications to make the code
easier to follow.
This is a partial backport of core#17487
https://github.com/bitcoin/bitcoin/pull/17487/commits/6d8affca96c7a34f5f104c5a3122e7420ffc083c
Depends on D16156
Test Plan: ninja check
Reviewers: #bitcoin_abc, Fabien
Reviewed By: #bitcoin_abc, Fabien
Differential Revision: https://reviews.bitcoinabc.org/D16161