Yes, that's a MacBook Pro (Retina, 13-inch, Early 2015)
It can run any OS from Mac OS X 10.10.2 to macOS 12 Monterey.
If you want to sell it, then I suggest you load it with the newest version of macOS that it can run - Monterey.
You can do that with a bootable USB installer, the guidance for which is linked in my previous post.
Or you can attempt to reinstall the latest OS from recovery by restarting your Intel-based Mac computer while holding Option-Command-R to startup from Internet Recovery. You'll need a strong wi-fi connection to do this. Optionally you can connect your Mac to your router with an Ethernet cable.
How to start up from macOS Recovery - Apple Support
In your original post you said you got an error. It will be helpful to tell us exactly what that error says.
Also, you must follow the guidance here: What to do before you sell, give away, trade in, or recycle your Mac - Apple Support