Heat olive oil in a skillet over medium-high heat. Brown beef cubes on all sides, then transfer to the slow cooker.
In the same skillet, sauté onions, garlic, carrots, and celery for 3-4 minutes until fragrant. Add tomato paste and cook for 1 minute.
Transfer vegetables to the slow cooker with the beef.
Pour in beef broth and red wine (if using). Add thyme, rosemary, bay leaves, salt, and pepper. Stir to combine.
Cover and cook on low for 7-8 hours or on high for 4-5 hours until beef and vegetables are tender.
If desired, mix 2 tablespoons flour with 1/4 cup cold water and stir into the stew. Cook an additional 15 minutes to thicken.
Add frozen peas and cook for another 5 minutes until heated through. Remove bay leaves before serving.