Add the ham to a food processor and pulse until very fine.
Melt the butter in a pan over medium heat, add the ham, and cook for 2–3 minutes until lightly browned and fragrant.
Add the flour, mix well, and cook for 2–3 minutes, stirring constantly, until a thick paste forms.
Pour in the milk and continue stirring until smooth and thick. Turn off the heat, mix in the cheese, and season with salt and black pepper.
Transfer the mixture to a container, spread it out, and let it cool completely. Refrigerate for 20 minutes hours until cooled.
Divide into 12 portions and shape into small logs or balls. Coat each one in flour, then egg, then breadcrumbs.
Heat oil over medium heat and fry until golden brown on all sides. Transfer to a rack to drain and serve warm. Buen provecho!