Place the dried beans in a large bowl, cover with at least 3 inches (7.5 cm) of cold water, and soak for 8 to 12 hours. Drain and rinse well.
Put the soaked beans in a large pot and cover with fresh water by 2 inches (5 cm). Bring to a boil, reduce to a gentle simmer, and cook until the beans are beginning to soften but still hold their shape, 45 to 60 minutes. Drain, reserving 1 cup (240 mL) of the cooking liquid. Heat the oven to 375°F (190°C).
Meanwhile, heat the olive oil in a large skillet over medium heat. Add the onion, carrots, celery, and 1/2 teaspoon salt. Cook, stirring occasionally, until softened, about 8 to 10 minutes. Add the garlic, oregano, paprika, and optional red pepper flakes; stir for 30 seconds.
Stir in the crushed tomatoes, vegetable broth, tomato paste, remaining 1 teaspoon salt, black pepper, dill, parsley, and reserved bean liquid. Bring the sauce to a gentle simmer and cook for 5 minutes.
Transfer the par-cooked beans and tomato sauce to a 9-by-13-inch (23-by-33-cm) baking dish or a 3-quart (2.8 L) casserole dish. The beans should be mostly covered with sauce; add a splash of broth or water if needed. Cover tightly with foil or a lid and bake for 40 minutes.
Uncover and bake until the beans are very tender and the sauce is thickened but still spoonable, 20 to 30 minutes longer. If the pan looks dry before the beans are tender, stir in a little hot water or broth and continue baking.
Let the dish rest for 10 minutes. Taste and add more salt, pepper, or optional lemon juice. Scatter with extra dill and parsley, then serve warm with crusty bread, rice, or a simple salad.