The minimum size of SPI flash write is a page. The page has to be erased first before attempt to write.
SPI Flash has to be divided into boot partition and data partition. If you haven’t divided into partitions, by default the entire flash size is taken as boot partition size and you cannot write data to SPI flash. These are only some of the reasons why you cannot write data to SPI flash. More details on flash devices are available in the xTIMEcomposer User Guide.