Silicone caulk is a flexible option and can be used, but ensure it is paintable if you plan to paint over it for a seamless finish.