Well, update to OP's indicates what is wanted is reversed ordered in the bookmarks. But bookmarks require hyperref, and the posted mwe does not use hyperref and the posted image does not show actual TOC of document.
Thus I am afraid I got started on this on wrong premises. Anyway, here is, adapted from https://tex.stackexchange.com/a/171556/4686 how to achieve this for the LaTeX generated TOC of the document. It is with or without hyperref, but bookmarks are not modified.
\documentclass{article}
\usepackage{hyperref}
\begin{document}
\newtoks\mytoks
\makeatletter
\@ifundefined{hyperref}
{\mytoks{\def\contentsline #1#2#3{%
\def\x{\contentsline {#1}{#2}{#3}}%
\toks@\expandafter\expandafter\expandafter
{\expandafter\x\the\toks@}%
}}}%
{\mytoks{\def\contentsline #1#2#3#4{%
\def\x{\contentsline {#1}{#2}{#3}{#4}}%
\toks@\expandafter\expandafter\expandafter
{\expandafter\x\the\toks@}%
}}}%
\addtocontents{toc}{\begingroup\toks@{}%
\string\the\string\mytoks}% extra \string for space token finicking
\AtEndDocument
{\addtocontents {toc}{\string\expandafter\string\endgroup\string\the\string\toks@}}
\makeatother
\tableofcontents
\section{A}
\subsection{A.1}
\section{B}
\subsection{B.1}
\section{C}
\subsection{C.1}
\section{D}
\subsection{D.1}
Hello there.
\end{document}

Adding subsections pretty much ruins the look of the TOC, but with only sections it would be fine.