MDM tools (there are several competing brands) allows low level access (essentially firmware), to manage devices. They are intially set up by Apple directly to allow complete management of devices. You cannot remove them yourself...erasing the drive won't change or remove the managed status.
As mentioned, there are two ways a managed Mac ends up outside of the controlling organizaion:
1. It is stolen, or ownership is otherwise in question
2. It was sold from the institution that owned and manage it, and they forgot to remove control from it.
If it was stolen, it won't be yours to keep, as you essentially bought stolen property. When you contact the controlling institution, they won't unlock it, and will likely ask for it back or send the police your way to collect it.
If it was forgotten or fell through the cracks, when you contact the controlling institution, they will de-actiave their MDM tools remotely, and you will be free to then erase the Mac normally...like any retail-purchased Mac. This is done via a web portal, so they don't need the Mac back to release it. Here is what happens, for example, to release a device from Apple School Manager for machines owned by educational institutions:
In Apple School Manager, you can remove an Apple device if it’s been sold, lost, or can’t be repaired.
support.apple.com
The Cisco profiles are a likely sign the machine is still enrolled in an MDM...but it is
possible to have profiles installed without an MDM connection. Odds arre very low; most likely it is still managed.