Does string theory accommodate effects of dark energy?
On one hand, according to observations, our universe has a positive cosmological constant $\Lambda>0$ associated with dark energy.
On the other hand, string theorists have so far not rigorously constructed a single 4D de Sitter stable vacuum with $\Lambda>0$ in string theory . A de Sitter swampland conjecture  suggests that they don't exist. See e.g. Ref. 3 for a popular review.
It has among other things been suggested that we instead live in a meta-stable universe, or a universe with quintessence.
U.H. Danielsson & T. Van Riet, What if string theory has no de Sitter vacua?, arXiv:1804.01120.
G. Obied, H. Ooguri, L. Spodyneiko & C. Vafa, De Sitter Space and the Swampland, arXiv:1806.08362.
N. Wolchover, Dark Energy May Be Incompatible With String Theory, Quantamagazine, august 2018.
At the level of the formalism, you don't need string theory to accomodate dark energy. Standard quantum field theory is perfectly able to have a cosmological constant simply by having a constant term in the Lagrangian density. In the absense of gravity, however, this energy is not measureable and we usually arbitrarily set this constant to zero. Since string theory reduces to quantum field theory in a low-energy limit, it therefore also can generate cosmological constants.
More specifically, a cosmological constant appears when the value of the potential of a field at the vacuum expectation value (VEV) of a field is non-zero, and there is nothing that intrinsically prohibits string theory from having models in which the effective QFT has such potentials/VEVs. However, a positive cosmological constant needs supersymmetry breaking, since unbroken supersymmetry forces the value of the potential at the VEV to be less than or equal to zero, and the landscape of non-supersymmetric compactification is still poorly understood (though perhaps not quite as poorly as it was), even almost 20 years after Witten wrote about it in "The Cosmological Constant From The Viewpoint Of String Theory".
So, in principle, string theory has no issues with a cosmological constant, since already QFT has no issues with it and is a limit of string theory. But, in practice, model building to get specific values for the constant is rather hard.