If you want to use custom style or other files stored in a specific directory in your Overleaf project with them recognised when you recompile, you can create a file called latexmkrc to point to this directory, for example:
# Custom locations to include content from
Elsevier journal style
$ENV{'TEXINPUTS'}='./tex/latex/elsevier//:' . $ENV{'TEXINPUTS'};
In the above code snippet, './tex/latex/elsevier' is a series of nested folders where I saved the Elsevier style which I downloaded from CTAN.

The above is based on directions I found in the Overleaf help library here, which in turn was based on a StackExchange post here.
There are additional directions found in the elsdoc.pdf file in the elsarticle download from CTAN, here.
Regarding the suggestion to use the Overleaf elsarticle template (here) - this may work, however when I downloaded the elsarticle.cls style following Elsevier directions in January 2021, I noted that the files appeared to have been last updated in 2020, which may be more recent than the linked template which contains a rendered preview dated 2019. As a new user on this board, my reputation was too low to reply to the comment directly so added this note to my answer here.
Hope this helps!
\documentclass{elsarticle}in your .tex file. Or start from https://www.overleaf.com/latex/examples/example-of-elsevier-article-template-with-dummy-text/qfscmwntknmq – imnothere Oct 22 '20 at 09:31