How can I change my stylesheet definition for a cell to optionally add a  caption (below and to the right)

[![enter image description here][1]][1]

like this (but to the right not centered):

[![enter image description here][2]][2]

There are something like this in the docs:

[![enter image description here][3]][3]


  [1]: https://i.sstatic.net/Ws4QA.png
  [2]: https://i.sstatic.net/TmrHw.png
  [3]: https://i.sstatic.net/GjMex.png