Young stellar objects (YSOs) represent the earliest stage in the process of star formation, offering insights that contribute to the development of models elucidating star formation and evolution. Recent advancements in deep-learning techniques have enabled significant strides in identifying special objects within vast data sets. In this paper, we present a YSO identification method based on deep-learning principles and spectra from the LAMOST. We designed a structure based on a long short-term memory network and a convolutional neural network and trained different models in two steps to identify YSO candidates. Initially, we trained a model to detect stellar spectra featuring the Hα emission line, achieving an accuracy of 98.67%. Leveraging this model, we classified 10,495,781 stellar spectra from LAMOST, yielding 76,867 candidates displaying a Hα emission line. Subsequently, we developed a YSO identification model, which achieved a recall rate of 95.81% for YSOs. Utilizing this model, we further identified 35,021 YSO candidates from the Hα emission-line candidates. Following cross validation, 3204 samples were identified as previously reported YSO candidates. We eliminated samples with low signal-to-noise ratios and M dwarfs by using the equivalent widths of the N ii and He i emission lines and visual inspection, resulting in a catalog of 20,530 YSO candidates. To facilitate future research endeavors, we provide the obtained catalogs of Hα emission-line star candidates and YSO candidates along with the code used for training the model.