This is a very basic, traditional recipe for refried beans, to which other spices can be added to taste.
Rinse beans well. Put in a pot and cover with water. Quarter Onion, chop celery, and add both to pot, along with salt. Simmer beans until soft, about two hours. Heat half an inch of oil in a large skillet over medium heat. Add beans to skillet, leaving water in the pot. Lower heat and mash beans. Add some water from pot. Simmer beans, stirring occasionally, until beans have reached desired consistency.