Apple 21.5" iMac 256GB MHK23LL/A (2019)

Apple 21.5" iMac 256GB MHK23LL/A (2019)

Can I use it just as a monitor?

In a word: No.

You might be able to use it to display another Apple device via desktop sharing.