  A search for a charged Higgs boson, $H^{\pm}$, produced in top-quark decays,
$t \rightarrow H^{\pm}b$, is presented. The search targets $H^{\pm}$ decays
into a bottom and a charm quark, $H^{\pm} \rightarrow cb$. The analysis focuses
on a selection enriched in top-quark pair production, where one top quark
decays into a leptonically decaying $W$ boson and a bottom quark, and the other
top quark decays into a charged Higgs boson and a bottom quark. This topology
leads to a lepton-plus-jets final state, characterised by an isolated electron
or muon and at least four jets. The search exploits the high multiplicity of
jets containing $b$-hadrons, and deploys a neural network classifier that uses
the kinematic differences between the signal and the background. The search
uses a dataset of proton-proton collisions collected at a centre-of-mass energy
$\sqrt{s}=13$ TeV between 2015 and 2018 with the ATLAS detector at CERN's Large
Hadron Collider, amounting to an integrated luminosity of 139 fb$^{-1}$.
Observed (expected) 95% confidence-level upper limits between 0.15% (0.09%) and
0.42% (0.25%) are derived for the product of branching fractions
$\mathscr{B}(t\rightarrow H^{\pm}b) \times \mathscr{B}(H^{\pm}\rightarrow cb)$
for charged Higgs boson masses between 60 and 160 GeV, assuming the SM
production of the top-quark pairs.
