Saute chicken in olive oil until cooked; remove from pan.
Add the beans (with liquid), lemon juice, garlic, rosemary, red pepper flakes and salt to pan. (If sauce seems a bit thick, add 1/4 cup of water) Bring to a boil, then turn heat down to simmer.
Return chicken to pan. Cover and let simmer for 30 minutes, stirring occasionally. If sauce becomes too thick, add a little water to the mixture.
After 30 minutes, add spinach to the pan and mix into the beans. Cover and let simmer for 10 minutes.
Serve with grated parmesan cheese if desired.